{
  "openapi": "3.0.3",
  "x-capabilitystatement-url": "https://fhir-ig.digital.health.nz/shared-care/CapabilityStatement/SharedCareFHIRAPICapabilityStatement",
  "x-capabilitystatement-id": "SharedCareFHIRAPICapabilityStatement",
  "info": {
    "version": "0.4.5",
    "title": "Health NZ | Te Whatu Ora Shared Care FHIR API",
    "description": "Health NZ | Te Whatu Ora Shared Care FHIR API",
    "license": {
      "name": "Health New Zealand Digital Services Hub API Access and Use Agreement",
      "url": "https://www.tewhatuora.govt.nz/assets/Our-health-system/Digital-health/Digital-Service-Hub/API-Access-and-Use-Agreement.docx"
    },
    "contact": {
      "name": "Health New Zealand Te Whatu Ora",
      "url": "https://www.tewhatuora.govt.nz"
    }
  },
  "externalDocs": {
    "url": "https://fhir-ig.digital.health.nz/shared-care",
    "description": "FHIR Implementation Guide"
  },
  "servers": [
    {
      "url": "https://fhir.api.digital.health.nz/R4",
      "description": "Health NZ | Te Whatu Ora Shared Care FHIR API"
    }
  ],
  "paths": {
    "/": {
      "post": {
        "summary": "System level interactions",
        "description": "System level interactions",
        "tags": [
          "system"
        ],
        "operationId": "systemInteractions",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful system level interaction",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "Bundle"
                      ],
                      "description": "Resource type must be a Bundle."
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "transaction-response"
                      ],
                      "description": "The type of response (e.g., transaction-response or batch-response)."
                    },
                    "entry": {
                      "type": "array",
                      "description": "Entries in the bundle representing resources involved in the interaction.",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resource": {
                            "type": "object",
                            "description": "A resource in the bundle."
                          },
                          "fullUrl": {
                            "type": "string",
                            "description": "The full url of the resource"
                          },
                          "search": {
                            "type": "object",
                            "properties": {
                              "mode": {
                                "type": "string",
                                "enum": [
                                  "match"
                                ],
                                "description": "The search mode."
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "resourceType": {
                    "type": "string",
                    "enum": [
                      "Bundle"
                    ],
                    "description": "Resource type must be a Bundle."
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "transaction"
                    ],
                    "description": "The type of bundle (e.g., transaction or batch)."
                  },
                  "entry": {
                    "type": "array",
                    "description": "Entries in the bundle representing resources involved in the interaction.",
                    "items": {
                      "type": "object",
                      "properties": {
                        "resource": {
                          "type": "object",
                          "description": "A resource in the bundle."
                        },
                        "request": {
                          "type": "object",
                          "description": "A resource in the bundle.",
                          "properties": {
                            "method": {
                              "type": "string",
                              "enum": [
                                "GET",
                                "POST",
                                "PUT",
                                "DELETE"
                              ],
                              "description": "The HTTP method used for the request."
                            },
                            "url": {
                              "type": "string",
                              "description": "The URL for the request."
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "https://fhir-ig.digital.health.nz/shared-care/OperationDefinition/RunOperation"
            ]
          },
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/Appointment.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/Appointment.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/Appointment.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/Appointment.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/Appointment.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/AppointmentResponse.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/AppointmentResponse.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/CarePlan.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/CarePlan.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/CarePlan.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/CarePlan.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/CarePlan.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/Condition.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/Condition.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/Condition.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/Condition.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/Condition.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/Consent.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/Consent.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/Consent.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/Consent.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/Consent.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/Encounter.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/Encounter.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/Encounter.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/Encounter.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/Encounter.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/Patient.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/Patient.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/Patient.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/Person.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/Person.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/Person.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/Person.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/Person.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/PlanDefinition.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/PlanDefinition.s"
            ]
          },
          {
            "smartOnFhir": [
              "https://fhir-ig.digital.health.nz/shared-care/OperationDefinition/PlanDefinition-apply"
            ]
          },
          {
            "smartOnFhir": [
              "system/Questionnaire.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/Questionnaire.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/QuestionnaireResponse.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/QuestionnaireResponse.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/QuestionnaireResponse.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/QuestionnaireResponse.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/QuestionnaireResponse.c"
            ]
          },
          {
            "smartOnFhir": [
              "https://fhir-ig.digital.health.nz/shared-care/OperationDefinition/QuestionnaireResponse-extract"
            ]
          },
          {
            "smartOnFhir": [
              "system/ActivityDefinition.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/ActivityDefinition.s"
            ]
          },
          {
            "smartOnFhir": [
              "https://fhir-ig.digital.health.nz/shared-care/OperationDefinition/ActivityDefinition-apply"
            ]
          },
          {
            "smartOnFhir": [
              "system/DocumentReference.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/DocumentReference.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/DocumentReference.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/DocumentReference.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/DocumentReference.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/Task.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/Task.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/Task.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/Task.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/Task.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/ServiceRequest.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/ServiceRequest.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/ServiceRequest.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/ServiceRequest.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/ServiceRequest.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/MedicationDispense.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/MedicationDispense.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/MedicationDispense.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/MedicationDispense.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/MedicationDispense.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/MedicationRequest.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/MedicationRequest.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/MedicationRequest.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/MedicationRequest.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/MedicationRequest.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/Claim.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/Claim.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/Claim.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/Claim.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/Claim.c"
            ]
          },
          {
            "smartOnFhir": [
              "system/ClaimResponse.r"
            ]
          },
          {
            "smartOnFhir": [
              "system/ClaimResponse.d"
            ]
          },
          {
            "smartOnFhir": [
              "system/ClaimResponse.u"
            ]
          },
          {
            "smartOnFhir": [
              "system/ClaimResponse.s"
            ]
          },
          {
            "smartOnFhir": [
              "system/ClaimResponse.c"
            ]
          }
        ]
      }
    },
    "/$run": {
      "post": {
        "summary": "run",
        "description": "Run a flat data view operation to aggregate data for a specific patient using a defined ViewDefinition.",
        "tags": [
          "system"
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "description": "This is a Binary resource",
                      "enum": [
                        "Binary"
                      ]
                    },
                    "id": {
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes.",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "type": "string"
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "contentType": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "Identifies the type of the data in the attachment and allows a method to be chosen to interpret or render the data. Includes mime type parameters such as charset where appropriate."
                    },
                    "securityContext": {
                      "description": "A reference from one resource to another.",
                      "type": "string"
                    },
                    "data": {
                      "type": "string",
                      "pattern": "(\\s*([0-9a-zA-Z\\+/=]){4}\\s*)+",
                      "description": "The actual content, base64 encoded."
                    }
                  },
                  "additionalProperties": false,
                  "required": [
                    "resourceType",
                    "contentType"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful run operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful run operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful run operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful run operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          }
        ],
        "security": [
          {
            "smartOnFhir": [
              "https://fhir-ig.digital.health.nz/shared-care/OperationDefinition/RunOperation"
            ]
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "resourceType": {
                    "type": "string",
                    "enum": [
                      "Parameters"
                    ]
                  },
                  "parameter": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "type": "string"
                        },
                        "valueString": {
                          "type": "string"
                        }
                      },
                      "additionalProperties": true,
                      "required": [
                        "name"
                      ]
                    }
                  }
                },
                "required": [
                  "resourceType",
                  "parameter"
                ]
              }
            }
          }
        },
        "operationId": "custom-run-system"
      }
    },
    "/AllergyIntolerance/{rid}": {
      "get": {
        "summary": "Read AllergyIntolerance",
        "description": "Read AllergyIntolerance",
        "tags": [
          "AllergyIntolerance"
        ],
        "operationId": "readAllergyIntolerance",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "description": "Resource id",
            "name": "rid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful read operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "AllergyIntolerance"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server.",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "clinicalStatus": {
                          "description": "The clinical status of the allergy or intolerance.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "verificationStatus": {
                          "description": "Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "allergy",
                            "intolerance"
                          ],
                          "description": "Identification of the underlying physiological mechanism for the reaction risk."
                        },
                        "category": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": [
                              "food",
                              "medication",
                              "environment",
                              "biologic"
                            ],
                            "description": "Category of the identified substance."
                          }
                        },
                        "code": {
                          "description": "Code for an allergy or intolerance statement (either a positive or a negated/excluded statement).  This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., \"Latex\"), an allergy or intolerance condition (e.g., \"Latex allergy\"), or a negated/excluded code for a specific substance or class (e.g., \"No latex allergy\") or a general or categorical negated statement (e.g.,  \"No known allergy\", \"No known drug allergies\").  Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "patient": {
                          "description": "The patient who has the allergy or intolerance.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "onsetDateTime": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                        },
                        "onsetAge": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "value": {
                              "type": "number",
                              "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                            },
                            "comparator": {
                              "type": "string",
                              "enum": [
                                "<",
                                "<=",
                                ">=",
                                ">"
                              ],
                              "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                            },
                            "unit": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human&ndash;readable form of the unit."
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The identification of the system that provides the coded form of the unit."
                            },
                            "code": {
                              "type": "string",
                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                              "description": "A computer processable form of the unit in some unit representation system."
                            }
                          }
                        },
                        "onsetPeriod": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        },
                        "onsetRange": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "low": {
                              "description": "The low limit. The boundary is inclusive.",
                              "type": "object",
                              "properties": {
                                "value": {
                                  "type": "number",
                                  "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                },
                                "comparator": {
                                  "type": "string",
                                  "enum": [
                                    "<",
                                    "<=",
                                    ">=",
                                    ">"
                                  ],
                                  "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                },
                                "unit": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human&ndash;readable form of the unit."
                                },
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the system that provides the coded form of the unit."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A computer processable form of the unit in some unit representation system."
                                }
                              }
                            },
                            "high": {
                              "description": "The high limit. The boundary is inclusive.",
                              "type": "object",
                              "properties": {
                                "value": {
                                  "type": "number",
                                  "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                },
                                "comparator": {
                                  "type": "string",
                                  "enum": [
                                    "<",
                                    "<=",
                                    ">=",
                                    ">"
                                  ],
                                  "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                },
                                "unit": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human&ndash;readable form of the unit."
                                },
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the system that provides the coded form of the unit."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A computer processable form of the unit in some unit representation system."
                                }
                              }
                            }
                          }
                        },
                        "onsetString": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                        },
                        "recorder": {
                          "description": "Individual who recorded the record and takes responsibility for its content.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "reaction": {
                          "type": "array",
                          "items": {
                            "description": "Details about each adverse reaction event linked to exposure to the identified substance.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "substance": {
                                "description": "Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "manifestation": {
                                "type": "array",
                                "items": {
                                  "description": "Clinical symptoms and/or signs that are observed or associated with the adverse reaction event.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                },
                                "minItems": 1
                              },
                              "description": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Text description about the reaction as a whole, including details of the manifestation if required."
                              },
                              "onset": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "Record of the date and/or time of the onset of the Reaction."
                              },
                              "severity": {
                                "type": "string",
                                "enum": [
                                  "mild",
                                  "moderate",
                                  "severe"
                                ],
                                "description": "Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations."
                              },
                              "exposureRoute": {
                                "description": "Identification of the route by which the subject was exposed to the substance.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "note": {
                                "type": "array",
                                "items": {
                                  "description": "Additional text about the adverse reaction event not captured in other fields.",
                                  "type": "object",
                                  "properties": {
                                    "authorReference": {
                                      "description": "The individual responsible for making the annotation.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    },
                                    "authorString": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The individual responsible for making the annotation."
                                    },
                                    "time": {
                                      "type": "string",
                                      "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                      "description": "Indicates when this particular annotation was made."
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The text of the annotation in markdown format."
                                    }
                                  },
                                  "required": [
                                    "text"
                                  ]
                                }
                              }
                            },
                            "required": [
                              "manifestation"
                            ]
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "patient"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiAllergyIntolerance"
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful read operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful read operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful read operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful read operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.r"
            ]
          }
        ]
      },
      "delete": {
        "summary": "Delete AllergyIntolerance",
        "description": "Delete AllergyIntolerance",
        "tags": [
          "AllergyIntolerance"
        ],
        "operationId": "deleteAllergyIntolerance",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "description": "Resource id",
            "name": "rid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful delete operation",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful delete operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful delete operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful delete operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful delete operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.d"
            ]
          }
        ]
      },
      "put": {
        "summary": "Update AllergyIntolerance",
        "description": "Update AllergyIntolerance",
        "tags": [
          "AllergyIntolerance"
        ],
        "operationId": "updateAllergyIntolerance",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "description": "Resource id",
            "name": "rid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful update operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "AllergyIntolerance"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server.",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "clinicalStatus": {
                          "description": "The clinical status of the allergy or intolerance.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "verificationStatus": {
                          "description": "Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "allergy",
                            "intolerance"
                          ],
                          "description": "Identification of the underlying physiological mechanism for the reaction risk."
                        },
                        "category": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": [
                              "food",
                              "medication",
                              "environment",
                              "biologic"
                            ],
                            "description": "Category of the identified substance."
                          }
                        },
                        "code": {
                          "description": "Code for an allergy or intolerance statement (either a positive or a negated/excluded statement).  This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., \"Latex\"), an allergy or intolerance condition (e.g., \"Latex allergy\"), or a negated/excluded code for a specific substance or class (e.g., \"No latex allergy\") or a general or categorical negated statement (e.g.,  \"No known allergy\", \"No known drug allergies\").  Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "patient": {
                          "description": "The patient who has the allergy or intolerance.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "onsetDateTime": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                        },
                        "onsetAge": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "value": {
                              "type": "number",
                              "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                            },
                            "comparator": {
                              "type": "string",
                              "enum": [
                                "<",
                                "<=",
                                ">=",
                                ">"
                              ],
                              "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                            },
                            "unit": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human&ndash;readable form of the unit."
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The identification of the system that provides the coded form of the unit."
                            },
                            "code": {
                              "type": "string",
                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                              "description": "A computer processable form of the unit in some unit representation system."
                            }
                          }
                        },
                        "onsetPeriod": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        },
                        "onsetRange": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "low": {
                              "description": "The low limit. The boundary is inclusive.",
                              "type": "object",
                              "properties": {
                                "value": {
                                  "type": "number",
                                  "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                },
                                "comparator": {
                                  "type": "string",
                                  "enum": [
                                    "<",
                                    "<=",
                                    ">=",
                                    ">"
                                  ],
                                  "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                },
                                "unit": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human&ndash;readable form of the unit."
                                },
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the system that provides the coded form of the unit."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A computer processable form of the unit in some unit representation system."
                                }
                              }
                            },
                            "high": {
                              "description": "The high limit. The boundary is inclusive.",
                              "type": "object",
                              "properties": {
                                "value": {
                                  "type": "number",
                                  "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                },
                                "comparator": {
                                  "type": "string",
                                  "enum": [
                                    "<",
                                    "<=",
                                    ">=",
                                    ">"
                                  ],
                                  "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                },
                                "unit": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human&ndash;readable form of the unit."
                                },
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the system that provides the coded form of the unit."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A computer processable form of the unit in some unit representation system."
                                }
                              }
                            }
                          }
                        },
                        "onsetString": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                        },
                        "recorder": {
                          "description": "Individual who recorded the record and takes responsibility for its content.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "reaction": {
                          "type": "array",
                          "items": {
                            "description": "Details about each adverse reaction event linked to exposure to the identified substance.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "substance": {
                                "description": "Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "manifestation": {
                                "type": "array",
                                "items": {
                                  "description": "Clinical symptoms and/or signs that are observed or associated with the adverse reaction event.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                },
                                "minItems": 1
                              },
                              "description": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Text description about the reaction as a whole, including details of the manifestation if required."
                              },
                              "onset": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "Record of the date and/or time of the onset of the Reaction."
                              },
                              "severity": {
                                "type": "string",
                                "enum": [
                                  "mild",
                                  "moderate",
                                  "severe"
                                ],
                                "description": "Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations."
                              },
                              "exposureRoute": {
                                "description": "Identification of the route by which the subject was exposed to the substance.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "note": {
                                "type": "array",
                                "items": {
                                  "description": "Additional text about the adverse reaction event not captured in other fields.",
                                  "type": "object",
                                  "properties": {
                                    "authorReference": {
                                      "description": "The individual responsible for making the annotation.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    },
                                    "authorString": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The individual responsible for making the annotation."
                                    },
                                    "time": {
                                      "type": "string",
                                      "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                      "description": "Indicates when this particular annotation was made."
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The text of the annotation in markdown format."
                                    }
                                  },
                                  "required": [
                                    "text"
                                  ]
                                }
                              }
                            },
                            "required": [
                              "manifestation"
                            ]
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "patient"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiAllergyIntolerance"
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful update operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful update operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful update operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful update operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "requestBody": {
          "description": "AllergyIntolerance to create",
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "resourceType": {
                        "type": "string",
                        "enum": [
                          "AllergyIntolerance"
                        ]
                      },
                      "id": {
                        "type": "string",
                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                        "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                      },
                      "meta": {
                        "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                        "type": "object",
                        "properties": {
                          "versionId": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                          },
                          "lastUpdated": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                            "description": "When the resource last changed &ndash; e.g. when the version changed."
                          },
                          "source": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                          },
                          "profile": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                            }
                          },
                          "security": {
                            "type": "array",
                            "items": {
                              "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "tag": {
                            "type": "array",
                            "items": {
                              "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          }
                        }
                      },
                      "text": {
                        "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                        "type": "object",
                        "properties": {
                          "status": {
                            "type": "string",
                            "enum": [
                              "generated",
                              "extensions",
                              "additional",
                              "empty"
                            ],
                            "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                          },
                          "div": {
                            "type": "string",
                            "description": "The actual narrative content, a stripped down version of XHTML."
                          }
                        },
                        "required": [
                          "status",
                          "div"
                        ]
                      },
                      "extension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "identifier": {
                        "type": "array",
                        "items": {
                          "description": "Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server.",
                          "type": "object",
                          "properties": {
                            "use": {
                              "type": "string",
                              "enum": [
                                "usual",
                                "official",
                                "temp",
                                "secondary",
                                "old"
                              ],
                              "description": "The purpose of this identifier."
                            },
                            "type": {
                              "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                            },
                            "value": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                            },
                            "period": {
                              "description": "Time period during which identifier is/was valid for use.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            },
                            "assigner": {
                              "description": "Organization that issued/manages the identifier.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            }
                          }
                        }
                      },
                      "clinicalStatus": {
                        "description": "The clinical status of the allergy or intolerance.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "verificationStatus": {
                        "description": "Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product).",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "allergy",
                          "intolerance"
                        ],
                        "description": "Identification of the underlying physiological mechanism for the reaction risk."
                      },
                      "category": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "enum": [
                            "food",
                            "medication",
                            "environment",
                            "biologic"
                          ],
                          "description": "Category of the identified substance."
                        }
                      },
                      "code": {
                        "description": "Code for an allergy or intolerance statement (either a positive or a negated/excluded statement).  This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., \"Latex\"), an allergy or intolerance condition (e.g., \"Latex allergy\"), or a negated/excluded code for a specific substance or class (e.g., \"No latex allergy\") or a general or categorical negated statement (e.g.,  \"No known allergy\", \"No known drug allergies\").  Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "patient": {
                        "description": "The patient who has the allergy or intolerance.",
                        "type": "object",
                        "properties": {
                          "reference": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                          },
                          "type": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                          },
                          "identifier": {
                            "type": "object",
                            "additionalProperties": true,
                            "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                          },
                          "display": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                          }
                        }
                      },
                      "onsetDateTime": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                        "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                      },
                      "onsetAge": {
                        "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                        "type": "object",
                        "properties": {
                          "value": {
                            "type": "number",
                            "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                          },
                          "comparator": {
                            "type": "string",
                            "enum": [
                              "<",
                              "<=",
                              ">=",
                              ">"
                            ],
                            "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                          },
                          "unit": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human&ndash;readable form of the unit."
                          },
                          "system": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "The identification of the system that provides the coded form of the unit."
                          },
                          "code": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "A computer processable form of the unit in some unit representation system."
                          }
                        }
                      },
                      "onsetPeriod": {
                        "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                        "type": "object",
                        "properties": {
                          "start": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                            "description": "The start of the period. The boundary is inclusive."
                          },
                          "end": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                            "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                          }
                        }
                      },
                      "onsetRange": {
                        "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                        "type": "object",
                        "properties": {
                          "low": {
                            "description": "The low limit. The boundary is inclusive.",
                            "type": "object",
                            "properties": {
                              "value": {
                                "type": "number",
                                "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                              },
                              "comparator": {
                                "type": "string",
                                "enum": [
                                  "<",
                                  "<=",
                                  ">=",
                                  ">"
                                ],
                                "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                              },
                              "unit": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human&ndash;readable form of the unit."
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the system that provides the coded form of the unit."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A computer processable form of the unit in some unit representation system."
                              }
                            }
                          },
                          "high": {
                            "description": "The high limit. The boundary is inclusive.",
                            "type": "object",
                            "properties": {
                              "value": {
                                "type": "number",
                                "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                              },
                              "comparator": {
                                "type": "string",
                                "enum": [
                                  "<",
                                  "<=",
                                  ">=",
                                  ">"
                                ],
                                "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                              },
                              "unit": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human&ndash;readable form of the unit."
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the system that provides the coded form of the unit."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A computer processable form of the unit in some unit representation system."
                              }
                            }
                          }
                        }
                      },
                      "onsetString": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                      },
                      "recorder": {
                        "description": "Individual who recorded the record and takes responsibility for its content.",
                        "type": "object",
                        "properties": {
                          "reference": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                          },
                          "type": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                          },
                          "identifier": {
                            "type": "object",
                            "additionalProperties": true,
                            "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                          },
                          "display": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                          }
                        }
                      },
                      "reaction": {
                        "type": "array",
                        "items": {
                          "description": "Details about each adverse reaction event linked to exposure to the identified substance.",
                          "type": "object",
                          "properties": {
                            "modifierExtension": {
                              "type": "array",
                              "items": {
                                "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                "type": "object",
                                "additionalProperties": true
                              }
                            },
                            "substance": {
                              "description": "Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "manifestation": {
                              "type": "array",
                              "items": {
                                "description": "Clinical symptoms and/or signs that are observed or associated with the adverse reaction event.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "minItems": 1
                            },
                            "description": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Text description about the reaction as a whole, including details of the manifestation if required."
                            },
                            "onset": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "Record of the date and/or time of the onset of the Reaction."
                            },
                            "severity": {
                              "type": "string",
                              "enum": [
                                "mild",
                                "moderate",
                                "severe"
                              ],
                              "description": "Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations."
                            },
                            "exposureRoute": {
                              "description": "Identification of the route by which the subject was exposed to the substance.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "note": {
                              "type": "array",
                              "items": {
                                "description": "Additional text about the adverse reaction event not captured in other fields.",
                                "type": "object",
                                "properties": {
                                  "authorReference": {
                                    "description": "The individual responsible for making the annotation.",
                                    "type": "object",
                                    "properties": {
                                      "reference": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                      },
                                      "type": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                      },
                                      "identifier": {
                                        "type": "object",
                                        "additionalProperties": true,
                                        "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                      }
                                    }
                                  },
                                  "authorString": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The individual responsible for making the annotation."
                                  },
                                  "time": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "Indicates when this particular annotation was made."
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The text of the annotation in markdown format."
                                  }
                                },
                                "required": [
                                  "text"
                                ]
                              }
                            }
                          },
                          "required": [
                            "manifestation"
                          ]
                        }
                      }
                    },
                    "required": [
                      "resourceType",
                      "patient"
                    ],
                    "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiAllergyIntolerance"
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.u"
            ]
          }
        ]
      }
    },
    "/AllergyIntolerance/{rid}/_history/{vid}": {
      "get": {
        "summary": "Read AllergyIntolerance (versioned)",
        "description": "Read AllergyIntolerance (versioned)",
        "tags": [
          "AllergyIntolerance"
        ],
        "operationId": "vreadAllergyIntolerance",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "description": "Resource id",
            "name": "rid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Resource version id",
            "name": "vid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful vread operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "AllergyIntolerance"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server.",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "clinicalStatus": {
                          "description": "The clinical status of the allergy or intolerance.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "verificationStatus": {
                          "description": "Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "allergy",
                            "intolerance"
                          ],
                          "description": "Identification of the underlying physiological mechanism for the reaction risk."
                        },
                        "category": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": [
                              "food",
                              "medication",
                              "environment",
                              "biologic"
                            ],
                            "description": "Category of the identified substance."
                          }
                        },
                        "code": {
                          "description": "Code for an allergy or intolerance statement (either a positive or a negated/excluded statement).  This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., \"Latex\"), an allergy or intolerance condition (e.g., \"Latex allergy\"), or a negated/excluded code for a specific substance or class (e.g., \"No latex allergy\") or a general or categorical negated statement (e.g.,  \"No known allergy\", \"No known drug allergies\").  Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "patient": {
                          "description": "The patient who has the allergy or intolerance.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "onsetDateTime": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                        },
                        "onsetAge": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "value": {
                              "type": "number",
                              "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                            },
                            "comparator": {
                              "type": "string",
                              "enum": [
                                "<",
                                "<=",
                                ">=",
                                ">"
                              ],
                              "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                            },
                            "unit": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human&ndash;readable form of the unit."
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The identification of the system that provides the coded form of the unit."
                            },
                            "code": {
                              "type": "string",
                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                              "description": "A computer processable form of the unit in some unit representation system."
                            }
                          }
                        },
                        "onsetPeriod": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        },
                        "onsetRange": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "low": {
                              "description": "The low limit. The boundary is inclusive.",
                              "type": "object",
                              "properties": {
                                "value": {
                                  "type": "number",
                                  "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                },
                                "comparator": {
                                  "type": "string",
                                  "enum": [
                                    "<",
                                    "<=",
                                    ">=",
                                    ">"
                                  ],
                                  "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                },
                                "unit": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human&ndash;readable form of the unit."
                                },
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the system that provides the coded form of the unit."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A computer processable form of the unit in some unit representation system."
                                }
                              }
                            },
                            "high": {
                              "description": "The high limit. The boundary is inclusive.",
                              "type": "object",
                              "properties": {
                                "value": {
                                  "type": "number",
                                  "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                },
                                "comparator": {
                                  "type": "string",
                                  "enum": [
                                    "<",
                                    "<=",
                                    ">=",
                                    ">"
                                  ],
                                  "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                },
                                "unit": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human&ndash;readable form of the unit."
                                },
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the system that provides the coded form of the unit."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A computer processable form of the unit in some unit representation system."
                                }
                              }
                            }
                          }
                        },
                        "onsetString": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                        },
                        "recorder": {
                          "description": "Individual who recorded the record and takes responsibility for its content.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "reaction": {
                          "type": "array",
                          "items": {
                            "description": "Details about each adverse reaction event linked to exposure to the identified substance.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "substance": {
                                "description": "Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "manifestation": {
                                "type": "array",
                                "items": {
                                  "description": "Clinical symptoms and/or signs that are observed or associated with the adverse reaction event.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                },
                                "minItems": 1
                              },
                              "description": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Text description about the reaction as a whole, including details of the manifestation if required."
                              },
                              "onset": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "Record of the date and/or time of the onset of the Reaction."
                              },
                              "severity": {
                                "type": "string",
                                "enum": [
                                  "mild",
                                  "moderate",
                                  "severe"
                                ],
                                "description": "Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations."
                              },
                              "exposureRoute": {
                                "description": "Identification of the route by which the subject was exposed to the substance.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "note": {
                                "type": "array",
                                "items": {
                                  "description": "Additional text about the adverse reaction event not captured in other fields.",
                                  "type": "object",
                                  "properties": {
                                    "authorReference": {
                                      "description": "The individual responsible for making the annotation.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    },
                                    "authorString": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The individual responsible for making the annotation."
                                    },
                                    "time": {
                                      "type": "string",
                                      "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                      "description": "Indicates when this particular annotation was made."
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The text of the annotation in markdown format."
                                    }
                                  },
                                  "required": [
                                    "text"
                                  ]
                                }
                              }
                            },
                            "required": [
                              "manifestation"
                            ]
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "patient"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiAllergyIntolerance"
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful vread operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful vread operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful vread operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful vread operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.r"
            ]
          }
        ]
      }
    },
    "/AllergyIntolerance": {
      "get": {
        "summary": "Search for AllergyIntolerance",
        "description": "Search for AllergyIntolerance",
        "tags": [
          "AllergyIntolerance"
        ],
        "operationId": "searchAllergyIntolerance",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "name": "patient",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "recorder",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "code",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "category",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "clinical-status",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "_id",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "_lastUpdated",
            "in": "query",
            "style": "form",
            "explode": true,
            "required": false,
            "schema": {
              "type": "string"
            },
            "examples": {
              "date": {
                "value": "2024-12-02"
              }
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful search operation",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "Bundle"
                      ],
                      "description": "Resource type must be a Bundle."
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "searchset"
                      ],
                      "description": "The type of response (e.g., transaction-response or batch-response)."
                    },
                    "entry": {
                      "type": "array",
                      "description": "Entries in the bundle representing resources involved in the interaction.",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resource": {
                            "type": "object",
                            "description": "A resource in the bundle.",
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "resourceType": {
                                    "type": "string",
                                    "enum": [
                                      "AllergyIntolerance"
                                    ]
                                  },
                                  "id": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                                  },
                                  "meta": {
                                    "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                    "type": "object",
                                    "properties": {
                                      "versionId": {
                                        "type": "string",
                                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                        "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                      },
                                      "lastUpdated": {
                                        "type": "string",
                                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                        "description": "When the resource last changed &ndash; e.g. when the version changed."
                                      },
                                      "source": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                      },
                                      "profile": {
                                        "type": "array",
                                        "items": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                        }
                                      },
                                      "security": {
                                        "type": "array",
                                        "items": {
                                          "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "tag": {
                                        "type": "array",
                                        "items": {
                                          "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                                    "type": "object",
                                    "properties": {
                                      "status": {
                                        "type": "string",
                                        "enum": [
                                          "generated",
                                          "extensions",
                                          "additional",
                                          "empty"
                                        ],
                                        "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                                      },
                                      "div": {
                                        "type": "string",
                                        "description": "The actual narrative content, a stripped down version of XHTML."
                                      }
                                    },
                                    "required": [
                                      "status",
                                      "div"
                                    ]
                                  },
                                  "extension": {
                                    "type": "array",
                                    "items": {
                                      "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                                      "type": "object",
                                      "additionalProperties": true
                                    }
                                  },
                                  "identifier": {
                                    "type": "array",
                                    "items": {
                                      "description": "Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server.",
                                      "type": "object",
                                      "properties": {
                                        "use": {
                                          "type": "string",
                                          "enum": [
                                            "usual",
                                            "official",
                                            "temp",
                                            "secondary",
                                            "old"
                                          ],
                                          "description": "The purpose of this identifier."
                                        },
                                        "type": {
                                          "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                          "type": "object",
                                          "properties": {
                                            "coding": {
                                              "type": "array",
                                              "items": {
                                                "description": "A reference to a code defined by a terminology system.",
                                                "type": "object",
                                                "properties": {
                                                  "system": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                  },
                                                  "version": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                  },
                                                  "code": {
                                                    "type": "string",
                                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                  },
                                                  "userSelected": {
                                                    "type": "boolean",
                                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                  }
                                                }
                                              }
                                            },
                                            "text": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                            }
                                          }
                                        },
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                                        },
                                        "value": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                                        },
                                        "period": {
                                          "description": "Time period during which identifier is/was valid for use.",
                                          "type": "object",
                                          "properties": {
                                            "start": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The start of the period. The boundary is inclusive."
                                            },
                                            "end": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                            }
                                          }
                                        },
                                        "assigner": {
                                          "description": "Organization that issued/manages the identifier.",
                                          "type": "object",
                                          "properties": {
                                            "reference": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                            },
                                            "type": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                            },
                                            "identifier": {
                                              "type": "object",
                                              "additionalProperties": true,
                                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                            }
                                          }
                                        }
                                      }
                                    }
                                  },
                                  "clinicalStatus": {
                                    "description": "The clinical status of the allergy or intolerance.",
                                    "type": "object",
                                    "properties": {
                                      "coding": {
                                        "type": "array",
                                        "items": {
                                          "description": "A reference to a code defined by a terminology system.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "text": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                      }
                                    }
                                  },
                                  "verificationStatus": {
                                    "description": "Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product).",
                                    "type": "object",
                                    "properties": {
                                      "coding": {
                                        "type": "array",
                                        "items": {
                                          "description": "A reference to a code defined by a terminology system.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "text": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                      }
                                    }
                                  },
                                  "type": {
                                    "type": "string",
                                    "enum": [
                                      "allergy",
                                      "intolerance"
                                    ],
                                    "description": "Identification of the underlying physiological mechanism for the reaction risk."
                                  },
                                  "category": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "enum": [
                                        "food",
                                        "medication",
                                        "environment",
                                        "biologic"
                                      ],
                                      "description": "Category of the identified substance."
                                    }
                                  },
                                  "code": {
                                    "description": "Code for an allergy or intolerance statement (either a positive or a negated/excluded statement).  This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., \"Latex\"), an allergy or intolerance condition (e.g., \"Latex allergy\"), or a negated/excluded code for a specific substance or class (e.g., \"No latex allergy\") or a general or categorical negated statement (e.g.,  \"No known allergy\", \"No known drug allergies\").  Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                                    "type": "object",
                                    "properties": {
                                      "coding": {
                                        "type": "array",
                                        "items": {
                                          "description": "A reference to a code defined by a terminology system.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "text": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                      }
                                    }
                                  },
                                  "patient": {
                                    "description": "The patient who has the allergy or intolerance.",
                                    "type": "object",
                                    "properties": {
                                      "reference": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                      },
                                      "type": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                      },
                                      "identifier": {
                                        "type": "object",
                                        "additionalProperties": true,
                                        "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                      }
                                    }
                                  },
                                  "onsetDateTime": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                                  },
                                  "onsetAge": {
                                    "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                                    "type": "object",
                                    "properties": {
                                      "value": {
                                        "type": "number",
                                        "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                      },
                                      "comparator": {
                                        "type": "string",
                                        "enum": [
                                          "<",
                                          "<=",
                                          ">=",
                                          ">"
                                        ],
                                        "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                      },
                                      "unit": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A human&ndash;readable form of the unit."
                                      },
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the system that provides the coded form of the unit."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A computer processable form of the unit in some unit representation system."
                                      }
                                    }
                                  },
                                  "onsetPeriod": {
                                    "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                                    "type": "object",
                                    "properties": {
                                      "start": {
                                        "type": "string",
                                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                        "description": "The start of the period. The boundary is inclusive."
                                      },
                                      "end": {
                                        "type": "string",
                                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                        "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                      }
                                    }
                                  },
                                  "onsetRange": {
                                    "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                                    "type": "object",
                                    "properties": {
                                      "low": {
                                        "description": "The low limit. The boundary is inclusive.",
                                        "type": "object",
                                        "properties": {
                                          "value": {
                                            "type": "number",
                                            "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                          },
                                          "comparator": {
                                            "type": "string",
                                            "enum": [
                                              "<",
                                              "<=",
                                              ">=",
                                              ">"
                                            ],
                                            "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                          },
                                          "unit": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A human&ndash;readable form of the unit."
                                          },
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the system that provides the coded form of the unit."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A computer processable form of the unit in some unit representation system."
                                          }
                                        }
                                      },
                                      "high": {
                                        "description": "The high limit. The boundary is inclusive.",
                                        "type": "object",
                                        "properties": {
                                          "value": {
                                            "type": "number",
                                            "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                          },
                                          "comparator": {
                                            "type": "string",
                                            "enum": [
                                              "<",
                                              "<=",
                                              ">=",
                                              ">"
                                            ],
                                            "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                          },
                                          "unit": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A human&ndash;readable form of the unit."
                                          },
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the system that provides the coded form of the unit."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A computer processable form of the unit in some unit representation system."
                                          }
                                        }
                                      }
                                    }
                                  },
                                  "onsetString": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                                  },
                                  "recorder": {
                                    "description": "Individual who recorded the record and takes responsibility for its content.",
                                    "type": "object",
                                    "properties": {
                                      "reference": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                      },
                                      "type": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                      },
                                      "identifier": {
                                        "type": "object",
                                        "additionalProperties": true,
                                        "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                      }
                                    }
                                  },
                                  "reaction": {
                                    "type": "array",
                                    "items": {
                                      "description": "Details about each adverse reaction event linked to exposure to the identified substance.",
                                      "type": "object",
                                      "properties": {
                                        "modifierExtension": {
                                          "type": "array",
                                          "items": {
                                            "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                            "type": "object",
                                            "additionalProperties": true
                                          }
                                        },
                                        "substance": {
                                          "description": "Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                                          "type": "object",
                                          "properties": {
                                            "coding": {
                                              "type": "array",
                                              "items": {
                                                "description": "A reference to a code defined by a terminology system.",
                                                "type": "object",
                                                "properties": {
                                                  "system": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                  },
                                                  "version": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                  },
                                                  "code": {
                                                    "type": "string",
                                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                  },
                                                  "userSelected": {
                                                    "type": "boolean",
                                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                  }
                                                }
                                              }
                                            },
                                            "text": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                            }
                                          }
                                        },
                                        "manifestation": {
                                          "type": "array",
                                          "items": {
                                            "description": "Clinical symptoms and/or signs that are observed or associated with the adverse reaction event.",
                                            "type": "object",
                                            "properties": {
                                              "coding": {
                                                "type": "array",
                                                "items": {
                                                  "description": "A reference to a code defined by a terminology system.",
                                                  "type": "object",
                                                  "properties": {
                                                    "system": {
                                                      "type": "string",
                                                      "pattern": "\\S*",
                                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                    },
                                                    "version": {
                                                      "type": "string",
                                                      "pattern": "[ \\r\\n\\t\\S]+",
                                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                    },
                                                    "code": {
                                                      "type": "string",
                                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                    },
                                                    "display": {
                                                      "type": "string",
                                                      "pattern": "[ \\r\\n\\t\\S]+",
                                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                    },
                                                    "userSelected": {
                                                      "type": "boolean",
                                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                    }
                                                  }
                                                }
                                              },
                                              "text": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                              }
                                            }
                                          },
                                          "minItems": 1
                                        },
                                        "description": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Text description about the reaction as a whole, including details of the manifestation if required."
                                        },
                                        "onset": {
                                          "type": "string",
                                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                          "description": "Record of the date and/or time of the onset of the Reaction."
                                        },
                                        "severity": {
                                          "type": "string",
                                          "enum": [
                                            "mild",
                                            "moderate",
                                            "severe"
                                          ],
                                          "description": "Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations."
                                        },
                                        "exposureRoute": {
                                          "description": "Identification of the route by which the subject was exposed to the substance.",
                                          "type": "object",
                                          "properties": {
                                            "coding": {
                                              "type": "array",
                                              "items": {
                                                "description": "A reference to a code defined by a terminology system.",
                                                "type": "object",
                                                "properties": {
                                                  "system": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                  },
                                                  "version": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                  },
                                                  "code": {
                                                    "type": "string",
                                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                  },
                                                  "userSelected": {
                                                    "type": "boolean",
                                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                  }
                                                }
                                              }
                                            },
                                            "text": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                            }
                                          }
                                        },
                                        "note": {
                                          "type": "array",
                                          "items": {
                                            "description": "Additional text about the adverse reaction event not captured in other fields.",
                                            "type": "object",
                                            "properties": {
                                              "authorReference": {
                                                "description": "The individual responsible for making the annotation.",
                                                "type": "object",
                                                "properties": {
                                                  "reference": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                                  },
                                                  "type": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                                  },
                                                  "identifier": {
                                                    "type": "object",
                                                    "additionalProperties": true,
                                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                                  }
                                                }
                                              },
                                              "authorString": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The individual responsible for making the annotation."
                                              },
                                              "time": {
                                                "type": "string",
                                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                                "description": "Indicates when this particular annotation was made."
                                              },
                                              "text": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The text of the annotation in markdown format."
                                              }
                                            },
                                            "required": [
                                              "text"
                                            ]
                                          }
                                        }
                                      },
                                      "required": [
                                        "manifestation"
                                      ]
                                    }
                                  }
                                },
                                "required": [
                                  "resourceType",
                                  "patient"
                                ],
                                "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiAllergyIntolerance"
                              }
                            ]
                          },
                          "fullUrl": {
                            "type": "string",
                            "description": "The full url of the resource"
                          },
                          "search": {
                            "type": "object",
                            "properties": {
                              "mode": {
                                "type": "string",
                                "enum": [
                                  "match"
                                ],
                                "description": "The search mode."
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful search operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful search operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful search operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful search operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.s"
            ]
          }
        ]
      },
      "post": {
        "summary": "Create AllergyIntolerance",
        "description": "Create AllergyIntolerance",
        "tags": [
          "AllergyIntolerance"
        ],
        "operationId": "createAllergyIntolerance",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Successful create operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "AllergyIntolerance"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server.",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "clinicalStatus": {
                          "description": "The clinical status of the allergy or intolerance.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "verificationStatus": {
                          "description": "Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "allergy",
                            "intolerance"
                          ],
                          "description": "Identification of the underlying physiological mechanism for the reaction risk."
                        },
                        "category": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": [
                              "food",
                              "medication",
                              "environment",
                              "biologic"
                            ],
                            "description": "Category of the identified substance."
                          }
                        },
                        "code": {
                          "description": "Code for an allergy or intolerance statement (either a positive or a negated/excluded statement).  This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., \"Latex\"), an allergy or intolerance condition (e.g., \"Latex allergy\"), or a negated/excluded code for a specific substance or class (e.g., \"No latex allergy\") or a general or categorical negated statement (e.g.,  \"No known allergy\", \"No known drug allergies\").  Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "patient": {
                          "description": "The patient who has the allergy or intolerance.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "onsetDateTime": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                        },
                        "onsetAge": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "value": {
                              "type": "number",
                              "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                            },
                            "comparator": {
                              "type": "string",
                              "enum": [
                                "<",
                                "<=",
                                ">=",
                                ">"
                              ],
                              "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                            },
                            "unit": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human&ndash;readable form of the unit."
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The identification of the system that provides the coded form of the unit."
                            },
                            "code": {
                              "type": "string",
                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                              "description": "A computer processable form of the unit in some unit representation system."
                            }
                          }
                        },
                        "onsetPeriod": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        },
                        "onsetRange": {
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                          "type": "object",
                          "properties": {
                            "low": {
                              "description": "The low limit. The boundary is inclusive.",
                              "type": "object",
                              "properties": {
                                "value": {
                                  "type": "number",
                                  "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                },
                                "comparator": {
                                  "type": "string",
                                  "enum": [
                                    "<",
                                    "<=",
                                    ">=",
                                    ">"
                                  ],
                                  "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                },
                                "unit": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human&ndash;readable form of the unit."
                                },
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the system that provides the coded form of the unit."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A computer processable form of the unit in some unit representation system."
                                }
                              }
                            },
                            "high": {
                              "description": "The high limit. The boundary is inclusive.",
                              "type": "object",
                              "properties": {
                                "value": {
                                  "type": "number",
                                  "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                },
                                "comparator": {
                                  "type": "string",
                                  "enum": [
                                    "<",
                                    "<=",
                                    ">=",
                                    ">"
                                  ],
                                  "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                },
                                "unit": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human&ndash;readable form of the unit."
                                },
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the system that provides the coded form of the unit."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A computer processable form of the unit in some unit representation system."
                                }
                              }
                            }
                          }
                        },
                        "onsetString": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                        },
                        "recorder": {
                          "description": "Individual who recorded the record and takes responsibility for its content.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "reaction": {
                          "type": "array",
                          "items": {
                            "description": "Details about each adverse reaction event linked to exposure to the identified substance.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "substance": {
                                "description": "Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "manifestation": {
                                "type": "array",
                                "items": {
                                  "description": "Clinical symptoms and/or signs that are observed or associated with the adverse reaction event.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                },
                                "minItems": 1
                              },
                              "description": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Text description about the reaction as a whole, including details of the manifestation if required."
                              },
                              "onset": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "Record of the date and/or time of the onset of the Reaction."
                              },
                              "severity": {
                                "type": "string",
                                "enum": [
                                  "mild",
                                  "moderate",
                                  "severe"
                                ],
                                "description": "Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations."
                              },
                              "exposureRoute": {
                                "description": "Identification of the route by which the subject was exposed to the substance.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "note": {
                                "type": "array",
                                "items": {
                                  "description": "Additional text about the adverse reaction event not captured in other fields.",
                                  "type": "object",
                                  "properties": {
                                    "authorReference": {
                                      "description": "The individual responsible for making the annotation.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    },
                                    "authorString": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The individual responsible for making the annotation."
                                    },
                                    "time": {
                                      "type": "string",
                                      "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                      "description": "Indicates when this particular annotation was made."
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The text of the annotation in markdown format."
                                    }
                                  },
                                  "required": [
                                    "text"
                                  ]
                                }
                              }
                            },
                            "required": [
                              "manifestation"
                            ]
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "patient"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiAllergyIntolerance"
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful create operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful create operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful create operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful create operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "requestBody": {
          "description": "AllergyIntolerance to create",
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "resourceType": {
                        "type": "string",
                        "enum": [
                          "AllergyIntolerance"
                        ]
                      },
                      "id": {
                        "type": "string",
                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                        "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                      },
                      "meta": {
                        "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                        "type": "object",
                        "properties": {
                          "versionId": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                          },
                          "lastUpdated": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                            "description": "When the resource last changed &ndash; e.g. when the version changed."
                          },
                          "source": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                          },
                          "profile": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                            }
                          },
                          "security": {
                            "type": "array",
                            "items": {
                              "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "tag": {
                            "type": "array",
                            "items": {
                              "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          }
                        }
                      },
                      "text": {
                        "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                        "type": "object",
                        "properties": {
                          "status": {
                            "type": "string",
                            "enum": [
                              "generated",
                              "extensions",
                              "additional",
                              "empty"
                            ],
                            "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                          },
                          "div": {
                            "type": "string",
                            "description": "The actual narrative content, a stripped down version of XHTML."
                          }
                        },
                        "required": [
                          "status",
                          "div"
                        ]
                      },
                      "extension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "identifier": {
                        "type": "array",
                        "items": {
                          "description": "Business identifiers assigned to this AllergyIntolerance by the performer or other systems which remain constant as the resource is updated and propagates from server to server.",
                          "type": "object",
                          "properties": {
                            "use": {
                              "type": "string",
                              "enum": [
                                "usual",
                                "official",
                                "temp",
                                "secondary",
                                "old"
                              ],
                              "description": "The purpose of this identifier."
                            },
                            "type": {
                              "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                            },
                            "value": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                            },
                            "period": {
                              "description": "Time period during which identifier is/was valid for use.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            },
                            "assigner": {
                              "description": "Organization that issued/manages the identifier.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            }
                          }
                        }
                      },
                      "clinicalStatus": {
                        "description": "The clinical status of the allergy or intolerance.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "verificationStatus": {
                        "description": "Assertion about certainty associated with the propensity, or potential risk, of a reaction to the identified substance (including pharmaceutical product).",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "allergy",
                          "intolerance"
                        ],
                        "description": "Identification of the underlying physiological mechanism for the reaction risk."
                      },
                      "category": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "enum": [
                            "food",
                            "medication",
                            "environment",
                            "biologic"
                          ],
                          "description": "Category of the identified substance."
                        }
                      },
                      "code": {
                        "description": "Code for an allergy or intolerance statement (either a positive or a negated/excluded statement).  This may be a code for a substance or pharmaceutical product that is considered to be responsible for the adverse reaction risk (e.g., \"Latex\"), an allergy or intolerance condition (e.g., \"Latex allergy\"), or a negated/excluded code for a specific substance or class (e.g., \"No latex allergy\") or a general or categorical negated statement (e.g.,  \"No known allergy\", \"No known drug allergies\").  Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "patient": {
                        "description": "The patient who has the allergy or intolerance.",
                        "type": "object",
                        "properties": {
                          "reference": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                          },
                          "type": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                          },
                          "identifier": {
                            "type": "object",
                            "additionalProperties": true,
                            "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                          },
                          "display": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                          }
                        }
                      },
                      "onsetDateTime": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                        "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                      },
                      "onsetAge": {
                        "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                        "type": "object",
                        "properties": {
                          "value": {
                            "type": "number",
                            "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                          },
                          "comparator": {
                            "type": "string",
                            "enum": [
                              "<",
                              "<=",
                              ">=",
                              ">"
                            ],
                            "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                          },
                          "unit": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human&ndash;readable form of the unit."
                          },
                          "system": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "The identification of the system that provides the coded form of the unit."
                          },
                          "code": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "A computer processable form of the unit in some unit representation system."
                          }
                        }
                      },
                      "onsetPeriod": {
                        "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                        "type": "object",
                        "properties": {
                          "start": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                            "description": "The start of the period. The boundary is inclusive."
                          },
                          "end": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                            "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                          }
                        }
                      },
                      "onsetRange": {
                        "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified.",
                        "type": "object",
                        "properties": {
                          "low": {
                            "description": "The low limit. The boundary is inclusive.",
                            "type": "object",
                            "properties": {
                              "value": {
                                "type": "number",
                                "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                              },
                              "comparator": {
                                "type": "string",
                                "enum": [
                                  "<",
                                  "<=",
                                  ">=",
                                  ">"
                                ],
                                "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                              },
                              "unit": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human&ndash;readable form of the unit."
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the system that provides the coded form of the unit."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A computer processable form of the unit in some unit representation system."
                              }
                            }
                          },
                          "high": {
                            "description": "The high limit. The boundary is inclusive.",
                            "type": "object",
                            "properties": {
                              "value": {
                                "type": "number",
                                "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                              },
                              "comparator": {
                                "type": "string",
                                "enum": [
                                  "<",
                                  "<=",
                                  ">=",
                                  ">"
                                ],
                                "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                              },
                              "unit": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human&ndash;readable form of the unit."
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the system that provides the coded form of the unit."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A computer processable form of the unit in some unit representation system."
                              }
                            }
                          }
                        }
                      },
                      "onsetString": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "Estimated or actual date,  date&ndash;time, or age when allergy or intolerance was identified."
                      },
                      "recorder": {
                        "description": "Individual who recorded the record and takes responsibility for its content.",
                        "type": "object",
                        "properties": {
                          "reference": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                          },
                          "type": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                          },
                          "identifier": {
                            "type": "object",
                            "additionalProperties": true,
                            "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                          },
                          "display": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                          }
                        }
                      },
                      "reaction": {
                        "type": "array",
                        "items": {
                          "description": "Details about each adverse reaction event linked to exposure to the identified substance.",
                          "type": "object",
                          "properties": {
                            "modifierExtension": {
                              "type": "array",
                              "items": {
                                "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                "type": "object",
                                "additionalProperties": true
                              }
                            },
                            "substance": {
                              "description": "Identification of the specific substance (or pharmaceutical product) considered to be responsible for the Adverse Reaction event. Note: the substance for a specific reaction may be different from the substance identified as the cause of the risk, but it must be consistent with it. For instance, it may be a more specific substance (e.g. a brand medication) or a composite product that includes the identified substance. It must be clinically safe to only process the 'code' and ignore the 'reaction.substance'.  If a receiving system is unable to confirm that AllergyIntolerance.reaction.substance falls within the semantic scope of AllergyIntolerance.code, then the receiving system should ignore AllergyIntolerance.reaction.substance.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "manifestation": {
                              "type": "array",
                              "items": {
                                "description": "Clinical symptoms and/or signs that are observed or associated with the adverse reaction event.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "minItems": 1
                            },
                            "description": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Text description about the reaction as a whole, including details of the manifestation if required."
                            },
                            "onset": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "Record of the date and/or time of the onset of the Reaction."
                            },
                            "severity": {
                              "type": "string",
                              "enum": [
                                "mild",
                                "moderate",
                                "severe"
                              ],
                              "description": "Clinical assessment of the severity of the reaction event as a whole, potentially considering multiple different manifestations."
                            },
                            "exposureRoute": {
                              "description": "Identification of the route by which the subject was exposed to the substance.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "note": {
                              "type": "array",
                              "items": {
                                "description": "Additional text about the adverse reaction event not captured in other fields.",
                                "type": "object",
                                "properties": {
                                  "authorReference": {
                                    "description": "The individual responsible for making the annotation.",
                                    "type": "object",
                                    "properties": {
                                      "reference": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                      },
                                      "type": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                      },
                                      "identifier": {
                                        "type": "object",
                                        "additionalProperties": true,
                                        "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                      }
                                    }
                                  },
                                  "authorString": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The individual responsible for making the annotation."
                                  },
                                  "time": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "Indicates when this particular annotation was made."
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The text of the annotation in markdown format."
                                  }
                                },
                                "required": [
                                  "text"
                                ]
                              }
                            }
                          },
                          "required": [
                            "manifestation"
                          ]
                        }
                      }
                    },
                    "required": [
                      "resourceType",
                      "patient"
                    ],
                    "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiAllergyIntolerance"
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/AllergyIntolerance.c"
            ]
          }
        ]
      }
    },
    "/metadata": {
      "get": {
        "summary": "Get CapabilityStatement",
        "description": "Returns the FHIR CapabilityStatement for this server",
        "tags": [
          "metadata"
        ],
        "operationId": "getCapabilityStatement",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful retrieval of the CapabilityStatement",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "CapabilityStatement"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "url": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "An absolute URI that is used to identify this capability statement when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this capability statement is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the capability statement is stored on different servers."
                    },
                    "version": {
                      "type": "string",
                      "pattern": "[ \\r\\n\\t\\S]+",
                      "description": "The identifier that is used to identify this version of the capability statement when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the capability statement author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence."
                    },
                    "name": {
                      "type": "string",
                      "pattern": "[ \\r\\n\\t\\S]+",
                      "description": "A natural language name identifying the capability statement. This name should be usable as an identifier for the module by machine processing applications such as code generation."
                    },
                    "title": {
                      "type": "string",
                      "pattern": "[ \\r\\n\\t\\S]+",
                      "description": "A short, descriptive, user&ndash;friendly title for the capability statement."
                    },
                    "status": {
                      "type": "string",
                      "enum": [
                        "draft",
                        "active",
                        "retired",
                        "unknown"
                      ],
                      "description": "The status of this capability statement. Enables tracking the life&ndash;cycle of the content."
                    },
                    "experimental": {
                      "type": "boolean",
                      "description": "A Boolean value to indicate that this capability statement is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage."
                    },
                    "date": {
                      "type": "string",
                      "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                      "description": "The date  (and optionally time) when the capability statement was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the capability statement changes."
                    },
                    "publisher": {
                      "type": "string",
                      "pattern": "[ \\r\\n\\t\\S]+",
                      "description": "The name of the organization or individual that published the capability statement."
                    },
                    "contact": {
                      "type": "array",
                      "items": {
                        "description": "Contact details to assist a user in finding and communicating with the publisher.",
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "The name of an individual to contact."
                          },
                          "telecom": {
                            "type": "array",
                            "items": {
                              "description": "The contact details for the individual (if a name was provided) or the organization.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "enum": [
                                    "phone",
                                    "fax",
                                    "email",
                                    "pager",
                                    "url",
                                    "sms",
                                    "other"
                                  ],
                                  "description": "Telecommunications form for contact point &ndash; what communications system is required to make use of the contact."
                                },
                                "value": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The actual contact point details, in a form that is meaningful to the designated communication system (i.e. phone number or email address)."
                                },
                                "use": {
                                  "type": "string",
                                  "enum": [
                                    "home",
                                    "work",
                                    "temp",
                                    "old",
                                    "mobile"
                                  ],
                                  "description": "Identifies the purpose for the contact point."
                                },
                                "rank": {
                                  "type": "integer",
                                  "format": "int32",
                                  "description": "Specifies a preferred order in which to use a set of contacts. ContactPoints with lower rank values are more preferred than those with higher rank values."
                                },
                                "period": {
                                  "description": "Time period when the contact point was/is in use.",
                                  "type": "object",
                                  "properties": {
                                    "start": {
                                      "type": "string",
                                      "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                      "description": "The start of the period. The boundary is inclusive."
                                    },
                                    "end": {
                                      "type": "string",
                                      "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                      "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    },
                    "description": {
                      "type": "string",
                      "pattern": "[ \\r\\n\\t\\S]+",
                      "description": "A free text natural language description of the capability statement from a consumer's perspective. Typically, this is used when the capability statement describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP."
                    },
                    "useContext": {
                      "type": "array",
                      "items": {
                        "description": "The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate capability statement instances.",
                        "type": "object",
                        "properties": {
                          "code": {
                            "description": "A code that identifies the type of context being specified by this usage context.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          },
                          "valueCodeableConcept": {
                            "description": "A value that defines the context specified in this context of use. The interpretation of the value is defined by the code.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "valueQuantity": {
                            "description": "A value that defines the context specified in this context of use. The interpretation of the value is defined by the code.",
                            "type": "object",
                            "properties": {
                              "value": {
                                "type": "number",
                                "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                              },
                              "comparator": {
                                "type": "string",
                                "enum": [
                                  "<",
                                  "<=",
                                  ">=",
                                  ">"
                                ],
                                "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                              },
                              "unit": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human&ndash;readable form of the unit."
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the system that provides the coded form of the unit."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A computer processable form of the unit in some unit representation system."
                              }
                            }
                          },
                          "valueRange": {
                            "description": "A value that defines the context specified in this context of use. The interpretation of the value is defined by the code.",
                            "type": "object",
                            "properties": {
                              "low": {
                                "description": "The low limit. The boundary is inclusive.",
                                "type": "object",
                                "properties": {
                                  "value": {
                                    "type": "number",
                                    "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                  },
                                  "comparator": {
                                    "type": "string",
                                    "enum": [
                                      "<",
                                      "<=",
                                      ">=",
                                      ">"
                                    ],
                                    "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                  },
                                  "unit": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human&ndash;readable form of the unit."
                                  },
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the system that provides the coded form of the unit."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A computer processable form of the unit in some unit representation system."
                                  }
                                }
                              },
                              "high": {
                                "description": "The high limit. The boundary is inclusive.",
                                "type": "object",
                                "properties": {
                                  "value": {
                                    "type": "number",
                                    "description": "The value of the measured amount. The value includes an implicit precision in the presentation of the value."
                                  },
                                  "comparator": {
                                    "type": "string",
                                    "enum": [
                                      "<",
                                      "<=",
                                      ">=",
                                      ">"
                                    ],
                                    "description": "How the value should be understood and represented &ndash; whether the actual value is greater or less than the stated value due to measurement issues; e.g. if the comparator is \"<\" , then the real value is < stated value."
                                  },
                                  "unit": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human&ndash;readable form of the unit."
                                  },
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the system that provides the coded form of the unit."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A computer processable form of the unit in some unit representation system."
                                  }
                                }
                              }
                            }
                          },
                          "valueReference": {
                            "description": "A value that defines the context specified in this context of use. The interpretation of the value is defined by the code.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "required": [
                          "code"
                        ]
                      }
                    },
                    "jurisdiction": {
                      "type": "array",
                      "items": {
                        "description": "A legal or geographic region in which the capability statement is intended to be used.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      }
                    },
                    "purpose": {
                      "type": "string",
                      "pattern": "[ \\r\\n\\t\\S]+",
                      "description": "Explanation of why this capability statement is needed and why it has been designed as it has."
                    },
                    "copyright": {
                      "type": "string",
                      "pattern": "[ \\r\\n\\t\\S]+",
                      "description": "A copyright statement relating to the capability statement and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the capability statement."
                    },
                    "kind": {
                      "type": "string",
                      "enum": [
                        "instance",
                        "capability",
                        "requirements"
                      ],
                      "description": "The way that this statement is intended to be used, to describe an actual running instance of software, a particular product (kind, not instance of software) or a class of implementation (e.g. a desired purchase)."
                    },
                    "instantiates": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "Reference to a canonical URL of another CapabilityStatement that this software implements. This capability statement is a published API description that corresponds to a business service. The server may actually implement a subset of the capability statement it claims to implement, so the capability statement must specify the full capability details."
                      }
                    },
                    "imports": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "Reference to a canonical URL of another CapabilityStatement that this software adds to. The capability statement automatically includes everything in the other statement, and it is not duplicated, though the server may repeat the same resources, interactions and operations to add additional details to them."
                      }
                    },
                    "software": {
                      "description": "Software that is covered by this capability statement.  It is used when the capability statement describes the capabilities of a particular software version, independent of an installation.",
                      "type": "object",
                      "properties": {
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "name": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Name the software is known by."
                        },
                        "version": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The version identifier for the software covered by this statement."
                        },
                        "releaseDate": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "Date this version of the software was released."
                        }
                      },
                      "required": [
                        "name"
                      ]
                    },
                    "implementation": {
                      "description": "Identifies a specific implementation instance that is described by the capability statement &ndash; i.e. a particular installation, rather than the capabilities of a software program.",
                      "type": "object",
                      "properties": {
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Information about the specific installation that this capability statement relates to."
                        },
                        "url": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "An absolute base URL for the implementation.  This forms the base for REST interfaces as well as the mailbox and document interfaces."
                        },
                        "custodian": {
                          "description": "The organization responsible for the management of the instance and oversight of the data on the server at the specified URL.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "required": [
                        "description"
                      ]
                    },
                    "fhirVersion": {
                      "type": "string",
                      "enum": [
                        "0.01",
                        "0.05",
                        "0.06",
                        "0.11",
                        "0.0.80",
                        "0.0.81",
                        "0.0.82",
                        "0.4.0",
                        "0.5.0",
                        "1.0.0",
                        "1.0.1",
                        "1.0.2",
                        "1.1.0",
                        "1.4.0",
                        "1.6.0",
                        "1.8.0",
                        "3.0.0",
                        "3.0.1",
                        "3.3.0",
                        "3.5.0",
                        "4.0.0",
                        "4.0.1"
                      ],
                      "description": "The version of the FHIR specification that this CapabilityStatement describes (which SHALL be the same as the FHIR version of the CapabilityStatement itself). There is no default value."
                    },
                    "format": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                        "description": "A list of the formats supported by this implementation using their content types."
                      },
                      "minItems": 1
                    },
                    "patchFormat": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                        "description": "A list of the patch formats supported by this implementation using their content types."
                      }
                    },
                    "implementationGuide": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "A list of implementation guides that the server does (or should) support in their entirety."
                      }
                    },
                    "rest": {
                      "type": "array",
                      "items": {
                        "description": "A definition of the restful capabilities of the solution, if any.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "mode": {
                            "type": "string",
                            "enum": [
                              "client",
                              "server"
                            ],
                            "description": "Identifies whether this portion of the statement is describing the ability to initiate or receive restful operations."
                          },
                          "documentation": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Information about the system's restful capabilities that apply across all applications, such as security."
                          },
                          "security": {
                            "description": "Information about security implementation from an interface perspective &ndash; what a client needs to know.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "cors": {
                                "type": "boolean",
                                "description": "Server adds CORS headers when responding to requests &ndash; this enables Javascript applications to use the server."
                              },
                              "service": {
                                "type": "array",
                                "items": {
                                  "description": "Types of security services that are supported/required by the system.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "description": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "General description of how security works."
                              }
                            }
                          },
                          "resource": {
                            "type": "array",
                            "items": {
                              "description": "A specification of the restful capabilities of the solution for a specific resource type.",
                              "type": "object",
                              "properties": {
                                "modifierExtension": {
                                  "type": "array",
                                  "items": {
                                    "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                    "type": "object",
                                    "additionalProperties": true
                                  }
                                },
                                "type": {
                                  "type": "string",
                                  "enum": [
                                    "Account",
                                    "ActivityDefinition",
                                    "AdverseEvent",
                                    "AllergyIntolerance",
                                    "Appointment",
                                    "AppointmentResponse",
                                    "AuditEvent",
                                    "Basic",
                                    "Binary",
                                    "BiologicallyDerivedProduct",
                                    "BodyStructure",
                                    "Bundle",
                                    "CapabilityStatement",
                                    "CarePlan",
                                    "CareTeam",
                                    "CatalogEntry",
                                    "ChargeItem",
                                    "ChargeItemDefinition",
                                    "Claim",
                                    "ClaimResponse",
                                    "ClinicalImpression",
                                    "CodeSystem",
                                    "Communication",
                                    "CommunicationRequest",
                                    "CompartmentDefinition",
                                    "Composition",
                                    "ConceptMap",
                                    "Condition",
                                    "Consent",
                                    "Contract",
                                    "Coverage",
                                    "CoverageEligibilityRequest",
                                    "CoverageEligibilityResponse",
                                    "DetectedIssue",
                                    "Device",
                                    "DeviceDefinition",
                                    "DeviceMetric",
                                    "DeviceRequest",
                                    "DeviceUseStatement",
                                    "DiagnosticReport",
                                    "DocumentManifest",
                                    "DocumentReference",
                                    "DomainResource",
                                    "EffectEvidenceSynthesis",
                                    "Encounter",
                                    "Endpoint",
                                    "EnrollmentRequest",
                                    "EnrollmentResponse",
                                    "EpisodeOfCare",
                                    "EventDefinition",
                                    "Evidence",
                                    "EvidenceVariable",
                                    "ExampleScenario",
                                    "ExplanationOfBenefit",
                                    "FamilyMemberHistory",
                                    "Flag",
                                    "Goal",
                                    "GraphDefinition",
                                    "Group",
                                    "GuidanceResponse",
                                    "HealthcareService",
                                    "ImagingStudy",
                                    "Immunization",
                                    "ImmunizationEvaluation",
                                    "ImmunizationRecommendation",
                                    "ImplementationGuide",
                                    "InsurancePlan",
                                    "Invoice",
                                    "Library",
                                    "Linkage",
                                    "List",
                                    "Location",
                                    "Measure",
                                    "MeasureReport",
                                    "Media",
                                    "Medication",
                                    "MedicationAdministration",
                                    "MedicationDispense",
                                    "MedicationKnowledge",
                                    "MedicationRequest",
                                    "MedicationStatement",
                                    "MedicinalProduct",
                                    "MedicinalProductAuthorization",
                                    "MedicinalProductContraindication",
                                    "MedicinalProductIndication",
                                    "MedicinalProductIngredient",
                                    "MedicinalProductInteraction",
                                    "MedicinalProductManufactured",
                                    "MedicinalProductPackaged",
                                    "MedicinalProductPharmaceutical",
                                    "MedicinalProductUndesirableEffect",
                                    "MessageDefinition",
                                    "MessageHeader",
                                    "MolecularSequence",
                                    "NamingSystem",
                                    "NutritionOrder",
                                    "Observation",
                                    "ObservationDefinition",
                                    "OperationDefinition",
                                    "OperationOutcome",
                                    "Organization",
                                    "OrganizationAffiliation",
                                    "Parameters",
                                    "Patient",
                                    "PaymentNotice",
                                    "PaymentReconciliation",
                                    "Person",
                                    "PlanDefinition",
                                    "Practitioner",
                                    "PractitionerRole",
                                    "Procedure",
                                    "Provenance",
                                    "Questionnaire",
                                    "QuestionnaireResponse",
                                    "RelatedPerson",
                                    "RequestGroup",
                                    "ResearchDefinition",
                                    "ResearchElementDefinition",
                                    "ResearchStudy",
                                    "ResearchSubject",
                                    "Resource",
                                    "RiskAssessment",
                                    "RiskEvidenceSynthesis",
                                    "Schedule",
                                    "SearchParameter",
                                    "ServiceRequest",
                                    "Slot",
                                    "Specimen",
                                    "SpecimenDefinition",
                                    "StructureDefinition",
                                    "StructureMap",
                                    "Subscription",
                                    "Substance",
                                    "SubstanceNucleicAcid",
                                    "SubstancePolymer",
                                    "SubstanceProtein",
                                    "SubstanceReferenceInformation",
                                    "SubstanceSourceMaterial",
                                    "SubstanceSpecification",
                                    "SupplyDelivery",
                                    "SupplyRequest",
                                    "Task",
                                    "TerminologyCapabilities",
                                    "TestReport",
                                    "TestScript",
                                    "ValueSet",
                                    "VerificationResult",
                                    "VisionPrescription"
                                  ],
                                  "description": "A type of resource exposed via the restful interface."
                                },
                                "profile": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A specification of the profile that describes the solution's overall support for the resource, including any constraints on cardinality, bindings, lengths or other limitations. See further discussion in [Using Profiles](profiling.html#profile&ndash;uses)."
                                },
                                "supportedProfile": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A list of profiles that represent different use cases supported by the system. For a server, \"supported by the system\" means the system hosts/produces a set of resources that are conformant to a particular profile, and allows clients that use its services to search using this profile and to find appropriate data. For a client, it means the system will search by this profile and process data according to the guidance implicit in the profile. See further discussion in [Using Profiles](profiling.html#profile&ndash;uses)."
                                  }
                                },
                                "documentation": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Additional information about the resource type used by the system."
                                },
                                "interaction": {
                                  "type": "array",
                                  "items": {
                                    "description": "Identifies a restful operation supported by the solution.",
                                    "type": "object",
                                    "properties": {
                                      "modifierExtension": {
                                        "type": "array",
                                        "items": {
                                          "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                          "type": "object",
                                          "additionalProperties": true
                                        }
                                      },
                                      "code": {
                                        "type": "string",
                                        "enum": [
                                          "read",
                                          "vread",
                                          "update",
                                          "patch",
                                          "delete",
                                          "history-instance",
                                          "history-type",
                                          "create",
                                          "search-type"
                                        ],
                                        "description": "Coded identifier of the operation, supported by the system resource."
                                      },
                                      "documentation": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre&ndash;authorized certificates only'."
                                      }
                                    },
                                    "required": [
                                      "code"
                                    ]
                                  }
                                },
                                "versioning": {
                                  "type": "string",
                                  "enum": [
                                    "no-version",
                                    "versioned",
                                    "versioned-update"
                                  ],
                                  "description": "This field is set to no&ndash;version to specify that the system does not support (server) or use (client) versioning for this resource type. If this has some other value, the server must at least correctly track and populate the versionId meta&ndash;property on resources. If the value is 'versioned&ndash;update', then the server supports all the versioning features, including using e&ndash;tags for version integrity in the API."
                                },
                                "readHistory": {
                                  "type": "boolean",
                                  "description": "A flag for whether the server is able to return past versions as part of the vRead operation."
                                },
                                "updateCreate": {
                                  "type": "boolean",
                                  "description": "A flag to indicate that the server allows or needs to allow the client to create new identities on the server (that is, the client PUTs to a location where there is no existing resource). Allowing this operation means that the server allows the client to create new identities on the server."
                                },
                                "conditionalCreate": {
                                  "type": "boolean",
                                  "description": "A flag that indicates that the server supports conditional create."
                                },
                                "conditionalRead": {
                                  "type": "string",
                                  "enum": [
                                    "not-supported",
                                    "modified-since",
                                    "not-match",
                                    "full-support"
                                  ],
                                  "description": "A code that indicates how the server supports conditional read."
                                },
                                "conditionalUpdate": {
                                  "type": "boolean",
                                  "description": "A flag that indicates that the server supports conditional update."
                                },
                                "conditionalDelete": {
                                  "type": "string",
                                  "enum": [
                                    "not-supported",
                                    "single",
                                    "multiple"
                                  ],
                                  "description": "A code that indicates how the server supports conditional delete."
                                },
                                "referencePolicy": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "enum": [
                                      "literal",
                                      "logical",
                                      "resolves",
                                      "enforced",
                                      "local"
                                    ],
                                    "description": "A set of flags that defines how references are supported."
                                  }
                                },
                                "searchInclude": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A list of _include values supported by the server."
                                  }
                                },
                                "searchRevInclude": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A list of _revinclude (reverse include) values supported by the server."
                                  }
                                },
                                "searchParam": {
                                  "type": "array",
                                  "items": {
                                    "description": "Search parameters for implementations to support and/or make use of &ndash; either references to ones defined in the specification, or additional ones defined for/by the implementation.",
                                    "type": "object",
                                    "properties": {
                                      "modifierExtension": {
                                        "type": "array",
                                        "items": {
                                          "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                          "type": "object",
                                          "additionalProperties": true
                                        }
                                      },
                                      "name": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The name of the search parameter used in the interface."
                                      },
                                      "definition": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "An absolute URI that is a formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter (a reference to [SearchParameter.url](searchparameter&ndash;definitions.html#SearchParameter.url)). This element SHALL be populated if the search parameter refers to a SearchParameter defined by the FHIR core specification or externally defined IGs."
                                      },
                                      "type": {
                                        "type": "string",
                                        "enum": [
                                          "number",
                                          "date",
                                          "string",
                                          "token",
                                          "reference",
                                          "composite",
                                          "quantity",
                                          "uri",
                                          "special"
                                        ],
                                        "description": "The type of value a search parameter refers to, and how the content is interpreted."
                                      },
                                      "documentation": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms."
                                      }
                                    },
                                    "required": [
                                      "name",
                                      "type"
                                    ]
                                  }
                                },
                                "operation": {
                                  "type": "array",
                                  "items": {
                                    "description": "Definition of an operation or a named query together with its parameters and their meaning and type. Consult the definition of the operation for details about how to invoke the operation, and the parameters.",
                                    "type": "object",
                                    "properties": {
                                      "modifierExtension": {
                                        "type": "array",
                                        "items": {
                                          "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                          "type": "object",
                                          "additionalProperties": true
                                        }
                                      },
                                      "name": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The name of the operation or query. For an operation, this is the name  prefixed with $ and used in the URL. For a query, this is the name used in the _query parameter when the query is called."
                                      },
                                      "definition": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "Where the formal definition can be found. If a server references the base definition of an Operation (i.e. from the specification itself such as ```http://hl7.org/fhir/OperationDefinition/ValueSet&ndash;expand```), that means it supports the full capabilities of the operation &ndash; e.g. both GET and POST invocation.  If it only supports a subset, it must define its own custom [OperationDefinition](operationdefinition.html#) with a 'base' of the original OperationDefinition.  The custom definition would describe the specific subset of functionality supported."
                                      },
                                      "documentation": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "Documentation that describes anything special about the operation behavior, possibly detailing different behavior for system, type and instance&ndash;level invocation of the operation."
                                      }
                                    },
                                    "required": [
                                      "name",
                                      "definition"
                                    ]
                                  }
                                }
                              },
                              "required": [
                                "type"
                              ]
                            }
                          },
                          "interaction": {
                            "type": "array",
                            "items": {
                              "description": "A specification of restful operations supported by the system.",
                              "type": "object",
                              "properties": {
                                "modifierExtension": {
                                  "type": "array",
                                  "items": {
                                    "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                    "type": "object",
                                    "additionalProperties": true
                                  }
                                },
                                "code": {
                                  "type": "string",
                                  "enum": [
                                    "transaction",
                                    "batch",
                                    "search-system",
                                    "history-system"
                                  ],
                                  "description": "Coded identifier of the operation, supported by the system resource."
                                },
                                "documentation": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Guidance specific to the implementation of this operation, such as 'delete is a logical delete' or 'updates are only allowed with version id' or 'creates permitted from pre&ndash;authorized certificates only'."
                                }
                              },
                              "required": [
                                "code"
                              ]
                            }
                          },
                          "searchParam": {
                            "type": "array",
                            "items": {
                              "description": "Search parameters that are supported for searching all resources for implementations to support and/or make use of &ndash; either references to ones defined in the specification, or additional ones defined for/by the implementation.",
                              "type": "object",
                              "properties": {
                                "modifierExtension": {
                                  "type": "array",
                                  "items": {
                                    "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                    "type": "object",
                                    "additionalProperties": true
                                  }
                                },
                                "name": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The name of the search parameter used in the interface."
                                },
                                "definition": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "An absolute URI that is a formal reference to where this parameter was first defined, so that a client can be confident of the meaning of the search parameter (a reference to [SearchParameter.url](searchparameter&ndash;definitions.html#SearchParameter.url)). This element SHALL be populated if the search parameter refers to a SearchParameter defined by the FHIR core specification or externally defined IGs."
                                },
                                "type": {
                                  "type": "string",
                                  "enum": [
                                    "number",
                                    "date",
                                    "string",
                                    "token",
                                    "reference",
                                    "composite",
                                    "quantity",
                                    "uri",
                                    "special"
                                  ],
                                  "description": "The type of value a search parameter refers to, and how the content is interpreted."
                                },
                                "documentation": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "This allows documentation of any distinct behaviors about how the search parameter is used.  For example, text matching algorithms."
                                }
                              },
                              "required": [
                                "name",
                                "type"
                              ]
                            }
                          },
                          "operation": {
                            "type": "array",
                            "items": {
                              "description": "Definition of an operation or a named query together with its parameters and their meaning and type.",
                              "type": "object",
                              "properties": {
                                "modifierExtension": {
                                  "type": "array",
                                  "items": {
                                    "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                    "type": "object",
                                    "additionalProperties": true
                                  }
                                },
                                "name": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The name of the operation or query. For an operation, this is the name  prefixed with $ and used in the URL. For a query, this is the name used in the _query parameter when the query is called."
                                },
                                "definition": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "Where the formal definition can be found. If a server references the base definition of an Operation (i.e. from the specification itself such as ```http://hl7.org/fhir/OperationDefinition/ValueSet&ndash;expand```), that means it supports the full capabilities of the operation &ndash; e.g. both GET and POST invocation.  If it only supports a subset, it must define its own custom [OperationDefinition](operationdefinition.html#) with a 'base' of the original OperationDefinition.  The custom definition would describe the specific subset of functionality supported."
                                },
                                "documentation": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Documentation that describes anything special about the operation behavior, possibly detailing different behavior for system, type and instance&ndash;level invocation of the operation."
                                }
                              },
                              "required": [
                                "name",
                                "definition"
                              ]
                            }
                          },
                          "compartment": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "An absolute URI which is a reference to the definition of a compartment that the system supports. The reference is to a CompartmentDefinition resource by its canonical URL ."
                            }
                          }
                        },
                        "required": [
                          "mode"
                        ]
                      }
                    },
                    "messaging": {
                      "type": "array",
                      "items": {
                        "description": "A description of the messaging capabilities of the solution.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "endpoint": {
                            "type": "array",
                            "items": {
                              "description": "An endpoint (network accessible address) to which messages and/or replies are to be sent.",
                              "type": "object",
                              "properties": {
                                "modifierExtension": {
                                  "type": "array",
                                  "items": {
                                    "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                    "type": "object",
                                    "additionalProperties": true
                                  }
                                },
                                "protocol": {
                                  "description": "A list of the messaging transport protocol(s) identifiers, supported by this endpoint.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                },
                                "address": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The network address of the endpoint. For solutions that do not use network addresses for routing, it can be just an identifier."
                                }
                              },
                              "required": [
                                "protocol",
                                "address"
                              ]
                            }
                          },
                          "reliableCache": {
                            "type": "integer",
                            "format": "int32",
                            "description": "Length if the receiver's reliable messaging cache in minutes (if a receiver) or how long the cache length on the receiver should be (if a sender)."
                          },
                          "documentation": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Documentation about the system's messaging capabilities for this endpoint not otherwise documented by the capability statement.  For example, the process for becoming an authorized messaging exchange partner."
                          },
                          "supportedMessage": {
                            "type": "array",
                            "items": {
                              "description": "References to message definitions for messages this system can send or receive.",
                              "type": "object",
                              "properties": {
                                "modifierExtension": {
                                  "type": "array",
                                  "items": {
                                    "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                    "type": "object",
                                    "additionalProperties": true
                                  }
                                },
                                "mode": {
                                  "type": "string",
                                  "enum": [
                                    "sender",
                                    "receiver"
                                  ],
                                  "description": "The mode of this event declaration &ndash; whether application is sender or receiver."
                                },
                                "definition": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "Points to a message definition that identifies the messaging event, message structure, allowed responses, etc."
                                }
                              },
                              "required": [
                                "mode",
                                "definition"
                              ]
                            }
                          }
                        }
                      }
                    },
                    "document": {
                      "type": "array",
                      "items": {
                        "description": "A document definition.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "mode": {
                            "type": "string",
                            "enum": [
                              "producer",
                              "consumer"
                            ],
                            "description": "Mode of this document declaration &ndash; whether an application is a producer or consumer."
                          },
                          "documentation": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A description of how the application supports or uses the specified document profile.  For example, when documents are created, what action is taken with consumed documents, etc."
                          },
                          "profile": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A profile on the document Bundle that constrains which resources are present, and their contents."
                          }
                        },
                        "required": [
                          "mode",
                          "profile"
                        ]
                      }
                    }
                  },
                  "required": [
                    "resourceType",
                    "status",
                    "date",
                    "kind",
                    "fhirVersion",
                    "format"
                  ]
                },
                "examples": {
                  "CapabilityStatement": {
                    "value": {
                      "resourceType": "CapabilityStatement",
                      "id": "SharedCareFHIRAPICapabilityStatement",
                      "meta": {
                        "profile": [
                          "https://fhir-ig.digital.health.nz/hnz-digital-tooling/StructureDefinition/hnz-capability-statement"
                        ]
                      },
                      "url": "https://fhir-ig.digital.health.nz/shared-care/CapabilityStatement/SharedCareFHIRAPICapabilityStatement",
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/hnz-digital-tooling/StructureDefinition/resource-metadata-extension",
                          "extension": [
                            {
                              "url": "licenseURL",
                              "valueUri": "https://www.tewhatuora.govt.nz/assets/Our-health-system/Digital-health/Digital-Service-Hub/API-Access-and-Use-Agreement.docx"
                            },
                            {
                              "url": "externalDocs",
                              "valueUri": "https://fhir-ig.digital.health.nz/shared-care"
                            },
                            {
                              "url": "licenseName",
                              "valueString": "Health New Zealand Digital Services Hub API Access and Use Agreement"
                            },
                            {
                              "extension": [
                                {
                                  "url": "https://fhir-ig.digital.health.nz/hnz-digital-tooling/StructureDefinition/custom-headers-extension",
                                  "extension": [
                                    {
                                      "url": "key",
                                      "valueString": "X-Correlation-Id"
                                    },
                                    {
                                      "url": "value",
                                      "valueUri": "https://raw.githubusercontent.com/tewhatuora/schemas/main/shared-care/Correlation-Id.json"
                                    },
                                    {
                                      "url": "required",
                                      "valueBoolean": true
                                    }
                                  ]
                                },
                                {
                                  "extension": [
                                    {
                                      "url": "key",
                                      "valueString": "Request-Context"
                                    },
                                    {
                                      "url": "value",
                                      "valueUri": "https://raw.githubusercontent.com/tewhatuora/schemas/main/shared-care/Request-Context.json"
                                    },
                                    {
                                      "url": "required",
                                      "valueBoolean": true
                                    }
                                  ],
                                  "url": "https://fhir-ig.digital.health.nz/hnz-digital-tooling/StructureDefinition/custom-headers-extension"
                                }
                              ],
                              "url": "globalHeaders"
                            }
                          ]
                        }
                      ],
                      "name": "SharedCareFHIRAPICapabilityStatement",
                      "title": "Shared Care FHIR Server Capability Statement",
                      "contact": [
                        {
                          "name": "Health New Zealand Te Whatu Ora",
                          "telecom": [
                            {
                              "value": "https://www.tewhatuora.govt.nz",
                              "system": "url"
                            }
                          ]
                        }
                      ],
                      "version": "0.4.5",
                      "status": "active",
                      "date": "2024-07-03",
                      "publisher": "Te Whatu Ora",
                      "description": "Health NZ | Te Whatu Ora Shared Care FHIR API",
                      "kind": "instance",
                      "implementation": {
                        "description": "Health NZ | Te Whatu Ora Shared Care FHIR API",
                        "url": "https://fhir.api.digital.health.nz/R4"
                      },
                      "fhirVersion": "4.0.1",
                      "format": [
                        "json"
                      ],
                      "rest": [
                        {
                          "mode": "server",
                          "security": {
                            "cors": true,
                            "service": [
                              {
                                "coding": [
                                  {
                                    "code": "SMART-on-FHIR"
                                  }
                                ]
                              }
                            ],
                            "extension": [
                              {
                                "url": "http://fhir-registry.smarthealthit.org/StructureDefinition/oauth-uris",
                                "extension": [
                                  {
                                    "url": "token",
                                    "valueUri": "https://ppd.auth.services.health.nz/realms/hnz-integration/protocol/openid-connect/token"
                                  }
                                ]
                              },
                              {
                                "url": "http://fhir-registry.smarthealthit.org/StructureDefinition/capabilities",
                                "valueCode": "client-confidential-symmetric"
                              }
                            ]
                          },
                          "interaction": [
                            {
                              "code": "transaction"
                            }
                          ],
                          "operation": [
                            {
                              "name": "run",
                              "definition": "https://fhir-ig.digital.health.nz/shared-care/OperationDefinition/RunOperation",
                              "documentation": "Run a flat data view operation to aggregate data for a specific patient using a defined ViewDefinition. See [Flat Data Views](./flatDataViews.md) for more information."
                            }
                          ],
                          "resource": [
                            {
                              "type": "AllergyIntolerance",
                              "profile": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiAllergyIntolerance",
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchInclude": [
                                "*"
                              ],
                              "searchParam": [
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference",
                                  "documentation": "Who the sensitivity is for \n [Patient](http://hl7.org/fhir/R4/patient.html)"
                                },
                                {
                                  "name": "recorder",
                                  "definition": "http://hl7.org/fhir/SearchParameter/AllergyIntolerance-recorder",
                                  "type": "reference",
                                  "documentation": "Who recorded the sensitivity \n [AllergyIntolerance.recorder](http://hl7.org/fhir/R4/allergyintolerance-definitions.html#AllergyIntolerance.recorder)"
                                },
                                {
                                  "name": "code",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-code",
                                  "type": "token",
                                  "documentation": "Code that identifies the allergy or intolerance \n [AllergyIntolerance Code ValueSet](http://hl7.org/fhir/ValueSet/allergyintolerance-code)"
                                },
                                {
                                  "name": "category",
                                  "definition": "http://hl7.org/fhir/SearchParameter/AllergyIntolerance-category",
                                  "type": "token",
                                  "documentation": "Must be one of \n* food\n* medication\n* environment\n* biologic \n [AllergyIntolerance Category ValueSet](http://hl7.org/fhir/ValueSet/allergy-intolerance-category)"
                                },
                                {
                                  "name": "clinical-status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/AllergyIntolerance-clinical-status",
                                  "type": "token",
                                  "documentation": "Must be one of \n* active\n * inactive\n * resolved\n[AllergyIntolerance Clinical Status ValueSet](http://hl7.org/fhir/R4/valueset-allergyintolerance-clinical.html)"
                                },
                                {
                                  "name": "_id",
                                  "definition": "https://build.fhir.org/ig/tewhatuora/cinc-fhir-ig/StructureDefinition-ManaakiNgaTahiAllergyIntolerance-definitions.html#AllergyIntolerance.id",
                                  "documentation": "[Resource Identifier](https://build.fhir.org/ig/tewhatuora/cinc-fhir-ig/StructureDefinition-ManaakiNgaTahiAllergyIntolerance-definitions.html#AllergyIntolerance.id)",
                                  "type": "token"
                                },
                                {
                                  "name": "_lastUpdated",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-lastUpdated",
                                  "type": "date",
                                  "documentation": "When the resource version last changed"
                                }
                              ]
                            },
                            {
                              "type": "Appointment",
                              "supportedProfile": [
                                "http://hl7.org/fhir/StructureDefinition/Appointment",
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment",
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchInclude": [
                                "*"
                              ],
                              "searchRevInclude": [
                                "*"
                              ],
                              "searchParam": [
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                },
                                {
                                  "name": "identifier",
                                  "definition": "https://hl7.org/fhir/searchparameter-registry.html#clinical-identifier",
                                  "type": "token",
                                  "documentation": "clinical-identifier"
                                },
                                {
                                  "name": "actor",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Appointment-actor",
                                  "type": "reference",
                                  "documentation": "Any one of the individuals participating in the appointment (Practitioner, Device, Patient, HealthcareService, PractitionerRole, RelatedPerson, Location)"
                                },
                                {
                                  "name": "appointment-type",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Appointment-appointment-type",
                                  "type": "token",
                                  "documentation": "Any one of the individuals participating in the appointment (Practitioner, Device, Patient, HealthcareService, PractitionerRole, RelatedPerson, Location)"
                                },
                                {
                                  "name": "date",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-date",
                                  "type": "date",
                                  "documentation": "Appointment date/time"
                                },
                                {
                                  "name": "location",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Appointment-location",
                                  "type": "reference",
                                  "documentation": "Appointment location"
                                },
                                {
                                  "name": "part-status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Appointment-part-status",
                                  "type": "token",
                                  "documentation": "Participation status of the Subject or other participant on the appointment"
                                },
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference",
                                  "documentation": "Who the appointment is for \n [Patient](http://hl7.org/fhir/R4/patient.html)"
                                },
                                {
                                  "name": "practitioner",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Appointment-practitioner",
                                  "type": "reference",
                                  "documentation": "Who the practitioner is \n [Practitioner](http://hl7.org/fhir/R4/practitioner.html)"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Appointment-status",
                                  "type": "token",
                                  "documentation": "proposed | pending | booked | arrived | fulfilled | cancelled | noshow | entered-in-error | checked-in | waitlist"
                                },
                                {
                                  "name": "appointment-method",
                                  "definition": "https://fhir-ig.digital.health.nz/shared-care/SearchParameter/dho-appointment-appointmentMethod",
                                  "type": "token",
                                  "documentation": "Search by appointment delivery method (Appointment.extension:appointmentMethod)"
                                }
                              ]
                            },
                            {
                              "type": "AppointmentResponse",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentResponse"
                              ],
                              "documentation": "Dunedin Hospital Outpatients - Used to confirm an appointment",
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "update"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": true,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported"
                            },
                            {
                              "type": "CarePlan",
                              "profile": "http://hl7.org/fhir/StructureDefinition/CarePlan",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiCarePlan"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchInclude": [
                                "*",
                                "CarePlan:encounter"
                              ],
                              "searchParam": [
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference",
                                  "documentation": "Who the care plan is for"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/CarePlan-status",
                                  "type": "token",
                                  "documentation": "draft | active | on-hold | revoked | completed | entered-in-error | unknown"
                                },
                                {
                                  "name": "subject",
                                  "definition": "http://hl7.org/fhir/SearchParameter/CarePlan-subject",
                                  "type": "reference",
                                  "documentation": "Who the care plan is for"
                                },
                                {
                                  "name": "_profile",
                                  "definition": "https://hl7.org/fhir/searchparameter-registry.html#Resource-profile",
                                  "type": "reference",
                                  "documentation": "Filter **RheumaticFeverCarePlan instances** using ?Resource-profile=https://build.fhir.org/ig/tewhatuora/cinc-fhir-ig/StructureDefinition/cinc-rheumaticfever-careplan"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                },
                                {
                                  "name": "category",
                                  "definition": "https://hl7.org/fhir/searchparameter-registry.html#CarePlan-category",
                                  "type": "token",
                                  "documentation": "Care plan search by category (SNOMED) code.  Rheumatic fever secondary prevention care plans have category=http://snomed.sct/info|320721000210102"
                                }
                              ]
                            },
                            {
                              "type": "Condition",
                              "profile": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiCondition",
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference",
                                  "documentation": "Who has the condition?"
                                },
                                {
                                  "name": "subject",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Condition-subject",
                                  "type": "reference",
                                  "documentation": "Who has the condition?"
                                },
                                {
                                  "name": "_profile",
                                  "definition": "https://hl7.org/fhir/searchparameter-registry.html#Resource-profile",
                                  "type": "reference",
                                  "documentation": "Filter **RheumaticFeverCondition instances** using ?Resource-profile=https://build.fhir.org/ig/tewhatuora/cinc-fhir-ig/StructureDefinition/cinc-rheumaticfever-condition"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                }
                              ]
                            },
                            {
                              "type": "Consent",
                              "profile": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/nz-sharedcare-consent",
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchInclude": [
                                "*",
                                "Consent:source-reference"
                              ],
                              "searchParam": [
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference",
                                  "documentation": "Who the consent applies to"
                                },
                                {
                                  "name": "data",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Consent-data",
                                  "type": "reference",
                                  "documentation": "The actual data reference"
                                },
                                {
                                  "name": "source-reference",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Consent-source-reference",
                                  "type": "reference",
                                  "documentation": "Search by reference to a Consent, DocumentReference, Contract  or QuestionnaireResponse"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Consent-status",
                                  "type": "token",
                                  "documentation": "draft | proposed | active | rejected | inactive | entered-in-error"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                }
                              ]
                            },
                            {
                              "type": "Encounter",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiEncounter",
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPEncounter",
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/UrgentCareEncounter",
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOEncounter",
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOEncounterCreate",
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOEncounterUpdate"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchInclude": [
                                "*",
                                "Encounter:diagnosis",
                                "Encounter:appointment",
                                "*",
                                "Observation:patient",
                                "Observation:encounter",
                                "Observation:based-on",
                                "Observation:derived-from",
                                "Observation:device",
                                "Observation:focus",
                                "Observation:has-member",
                                "Observation:part-of",
                                "Observation:performer",
                                "Observation:specimen",
                                "Observation:subject"
                              ],
                              "searchParam": [
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                },
                                {
                                  "name": "identifier",
                                  "definition": "https://hl7.org/fhir/searchparameter-registry.html#clinical-identifier",
                                  "type": "token",
                                  "documentation": "clinical-identifier"
                                },
                                {
                                  "name": "appointment",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Encounter-appointment",
                                  "type": "reference",
                                  "documentation": "The appointment associated with the encounter"
                                },
                                {
                                  "name": "date",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-date",
                                  "type": "date",
                                  "documentation": "A date within the period the Encounter lasted"
                                },
                                {
                                  "name": "date-start",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Encounter-date-start",
                                  "type": "date",
                                  "documentation": "The actual start date of the Encounter"
                                },
                                {
                                  "name": "date-end",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Encounter-date-end",
                                  "type": "date",
                                  "documentation": "The actual end date of the Encounter"
                                },
                                {
                                  "name": "location",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Encounter-location",
                                  "type": "reference",
                                  "documentation": "Location the encounter takes place"
                                },
                                {
                                  "name": "participant",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Encounter-participant",
                                  "type": "reference",
                                  "documentation": "Persons involved in the encounter other than the patient"
                                },
                                {
                                  "name": "participant-type",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Encounter-participant-type",
                                  "type": "reference",
                                  "documentation": "Persons involved in the encounter other than the patient"
                                },
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference",
                                  "documentation": "The patient or group present at the encounter"
                                },
                                {
                                  "name": "practitioner",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Encounter-practitioner",
                                  "type": "reference",
                                  "documentation": "Persons involved in the encounter other than the patient"
                                },
                                {
                                  "name": "subject-status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Encounter-subject-status",
                                  "type": "token",
                                  "documentation": "The classification of the type of observation"
                                },
                                {
                                  "name": "derived-from",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Observation-derived-from",
                                  "type": "reference",
                                  "documentation": "Related measurements the observation is made from"
                                },
                                {
                                  "name": "performer",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Observation-performer",
                                  "type": "reference",
                                  "documentation": "Who performed the observation"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Observation-status",
                                  "type": "token",
                                  "documentation": "The status of the observation"
                                },
                                {
                                  "name": "subject",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Observation-subject",
                                  "type": "reference",
                                  "documentation": "The subject that the observation is about"
                                },
                                {
                                  "name": "value-concept",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Observation-value-concept",
                                  "type": "token",
                                  "documentation": "The value of the observation, if the value is a CodeableConcept"
                                },
                                {
                                  "name": "value-date",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Observation-value-date",
                                  "type": "date",
                                  "documentation": "The value of the observation, if the value is a date or period of time"
                                },
                                {
                                  "name": "value-quantity",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Observation-value-quantity",
                                  "type": "quantity",
                                  "documentation": "The value of the observation, if the value is a Quantity, or a SampledData (just search on the bounds of the values in sampled data)"
                                },
                                {
                                  "name": "value-string",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Observation-value-string",
                                  "type": "string",
                                  "documentation": "The value of the observation, if the value is a string, and also searches in CodeableConcept.text"
                                },
                                {
                                  "name": "_lastUpdated",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-lastUpdated",
                                  "type": "date",
                                  "documentation": "When the resource version last changed"
                                }
                              ]
                            },
                            {
                              "type": "Patient",
                              "profile": "http://hl7.org.nz/fhir/StructureDefinition/NzPatient",
                              "documentation": "Dunedin Hospital Outpatients - Patient Profile",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOPatientUpdate"
                              ],
                              "interaction": [
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchInclude": [
                                "*"
                              ],
                              "searchParam": [
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                },
                                {
                                  "name": "identifier",
                                  "definition": "https://hl7.org/fhir/searchparameter-registry.html#Patient-identifier",
                                  "type": "token",
                                  "documentation": "The patient's official NHI identifier"
                                },
                                {
                                  "name": "_profile",
                                  "definition": "https://hl7.org/fhir/searchparameter-registry.html#Resource-profile",
                                  "type": "reference",
                                  "documentation": "Filter **Patient instances** using the applicable profile canonical Url from IG"
                                },
                                {
                                  "name": "individual-family",
                                  "definition": "https://www.hl7.org/fhir/R4/searchparameter-registry.html#individual-family",
                                  "type": "string",
                                  "documentation": "A portion of the family name of the patient - Patient.name.family"
                                },
                                {
                                  "name": "individual-given",
                                  "definition": "https://www.hl7.org/fhir/R4/searchparameter-registry.html#individual-given",
                                  "type": "string",
                                  "documentation": "A portion of the given name of the patient - Patient.name.given"
                                },
                                {
                                  "name": "Patient-name",
                                  "definition": "https://www.hl7.org/fhir/R4/searchparameter-registry.html#Patient-name",
                                  "type": "string",
                                  "documentation": "A server defined search that may match any of the string fields in the HumanName, including family, give, prefix, suffix, suffix, and/or text - Patient.name"
                                },
                                {
                                  "name": "individual-phonetic",
                                  "definition": "https://www.hl7.org/fhir/R4/searchparameter-registry.html#individual-phonetic",
                                  "type": "string",
                                  "documentation": "A portion of either family or given name using some kind of phonetic matching algorithm - Patient.name"
                                },
                                {
                                  "name": "individual-email",
                                  "definition": "https://www.hl7.org/fhir/R4/searchparameter-registry.html#individual-email",
                                  "type": "string",
                                  "documentation": "Patient's email contact record - Patient.telecom.where(system='email') | Person"
                                }
                              ]
                            },
                            {
                              "type": "Person",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/nz-sharedcare-communication-person"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "phone",
                                  "definition": "https://hl7.org/fhir/searchparameter-registry.html#individual-phone",
                                  "type": "token",
                                  "documentation": "A value in a phone contact."
                                },
                                {
                                  "name": "email",
                                  "definition": "http://hl7.org/fhir/SearchParameter/individual-email",
                                  "type": "token",
                                  "documentation": "A value in an email contact"
                                },
                                {
                                  "name": "identifier",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-identifier",
                                  "type": "token",
                                  "documentation": "A person Identifier"
                                },
                                {
                                  "name": "_profile",
                                  "definition": "https://hl7.org/fhir/searchparameter-registry.html#Resource-profile",
                                  "type": "reference",
                                  "documentation": "Filter **Person Instances** using ?profile=https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/nz-sharedcare-communication-person"
                                },
                                {
                                  "name": "_source",
                                  "definition": "https://hl7.org/fhir/searchparameter-registry.html#Resource-source",
                                  "type": "uri",
                                  "documentation": "Filter **Person Instances** using the meta.source field - e.g. ?_source=NIBS"
                                }
                              ]
                            },
                            {
                              "type": "PlanDefinition",
                              "profile": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/ManaakiNgaTahiPlanDefinition",
                              "interaction": [
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "identifier",
                                  "definition": "http://hl7.org/fhir/SearchParameter/PlanDefinition-identifier",
                                  "type": "token",
                                  "documentation": "External identifier for the plan definition"
                                },
                                {
                                  "name": "name",
                                  "definition": "http://hl7.org/fhir/SearchParameter/PlanDefinition-name",
                                  "type": "string",
                                  "documentation": "Computationally friendly name of the plan definition"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/PlanDefinition-status",
                                  "type": "token",
                                  "documentation": "The current status of the plan definition"
                                },
                                {
                                  "name": "title",
                                  "definition": "http://hl7.org/fhir/SearchParameter/PlanDefinition-title",
                                  "type": "string",
                                  "documentation": "The human-friendly name of the plan definition"
                                },
                                {
                                  "name": "url",
                                  "definition": "http://hl7.org/fhir/SearchParameter/PlanDefinition-url",
                                  "type": "uri",
                                  "documentation": "The uri that identifies the plan definition"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                }
                              ],
                              "operation": [
                                {
                                  "name": "apply",
                                  "definition": "https://fhir-ig.digital.health.nz/shared-care/OperationDefinition/PlanDefinition-apply"
                                }
                              ]
                            },
                            {
                              "type": "Questionnaire",
                              "interaction": [
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "identifier",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Questionnaire-identifier",
                                  "type": "token",
                                  "documentation": "External identifier for the questionnaire"
                                },
                                {
                                  "name": "name",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Questionnaire-name",
                                  "type": "string",
                                  "documentation": "Computationally friendly name of the questionnaire"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Questionnaire-status",
                                  "type": "token",
                                  "documentation": "The current status of the questionnaire"
                                },
                                {
                                  "name": "title",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Questionnaire-title",
                                  "type": "string",
                                  "documentation": "The human-friendly name of the questionnaire"
                                },
                                {
                                  "name": "url",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Questionnaire-url",
                                  "type": "uri",
                                  "documentation": "The uri that identifies the questionnaire"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                }
                              ]
                            },
                            {
                              "type": "QuestionnaireResponse",
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchInclude": [
                                "*",
                                "QuestionnaireResponse:based-on",
                                "QuestionnaireResponse:encounter"
                              ],
                              "searchParam": [
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/QuestionnaireResponse-patient",
                                  "type": "reference",
                                  "documentation": "The patient that is the subject of the questionnaire response"
                                },
                                {
                                  "name": "questionnaire",
                                  "definition": "http://hl7.org/fhir/SearchParameter/QuestionnaireResponse-questionnaire",
                                  "type": "reference",
                                  "documentation": "The questionnaire the answers are provided for"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/QuestionnaireResponse-status",
                                  "type": "token",
                                  "documentation": "The status of the questionnaire response"
                                },
                                {
                                  "name": "subject",
                                  "definition": "http://hl7.org/fhir/SearchParameter/QuestionnaireResponse-subject",
                                  "type": "reference",
                                  "documentation": "The subject of the questionnaire response"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                }
                              ],
                              "operation": [
                                {
                                  "name": "extract",
                                  "definition": "https://fhir-ig.digital.health.nz/shared-care/OperationDefinition/QuestionnaireResponse-extract"
                                }
                              ]
                            },
                            {
                              "type": "ActivityDefinition",
                              "interaction": [
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchInclude": [
                                "*"
                              ],
                              "searchParam": [
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                },
                                {
                                  "name": "identifier",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ActivityDefinition-identifier",
                                  "type": "token",
                                  "documentation": "External identifier for the ActivityDefinition"
                                },
                                {
                                  "name": "name",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ActivityDefinition-name",
                                  "type": "string",
                                  "documentation": "Computationally friendly name of the ActivityDefinition"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ActivityDefinition-status",
                                  "type": "token",
                                  "documentation": "The current status of the ActivityDefinition"
                                },
                                {
                                  "name": "title",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ActivityDefinition-title",
                                  "type": "string",
                                  "documentation": "The human-friendly name of the ActivityDefinition"
                                }
                              ],
                              "operation": [
                                {
                                  "name": "apply",
                                  "definition": "https://fhir-ig.digital.health.nz/shared-care/OperationDefinition/ActivityDefinition-apply"
                                }
                              ]
                            },
                            {
                              "type": "DocumentReference",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/TemplateDocumentReference"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "identifier",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-identifier",
                                  "type": "token",
                                  "documentation": "Identifier of the attachment binary"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/DocumentReference-status",
                                  "type": "token",
                                  "documentation": "current | superseded | entered-in-error"
                                },
                                {
                                  "name": "category",
                                  "definition": "http://hl7.org/fhir/SearchParameter/DocumentReference-category",
                                  "type": "token",
                                  "documentation": "Categorization of document"
                                },
                                {
                                  "name": "date",
                                  "definition": "http://hl7.org/fhir/SearchParameter/DocumentReference-date",
                                  "type": "date",
                                  "documentation": "When this document reference was createdr"
                                }
                              ]
                            },
                            {
                              "type": "Task",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OutreachTask"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Task-status",
                                  "type": "token"
                                },
                                {
                                  "name": "code",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Task-code",
                                  "type": "token",
                                  "documentation": "The type of outreach task"
                                },
                                {
                                  "name": "owner",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Task-owner",
                                  "type": "reference"
                                },
                                {
                                  "name": "subject",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Task-subject",
                                  "type": "reference"
                                },
                                {
                                  "name": "requester",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Task-requester",
                                  "type": "reference"
                                },
                                {
                                  "name": "based-on",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Task-based-on",
                                  "type": "reference"
                                },
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                }
                              ]
                            },
                            {
                              "type": "ServiceRequest",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OutreachServiceRequest"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "identifier",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-identifier",
                                  "type": "token"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ServiceRequest-status",
                                  "type": "token"
                                },
                                {
                                  "name": "priority",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ServiceRequest-priority",
                                  "type": "token"
                                },
                                {
                                  "name": "code",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-code",
                                  "type": "token"
                                },
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference"
                                },
                                {
                                  "name": "subject",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ServiceRequest-subject",
                                  "type": "reference"
                                },
                                {
                                  "name": "performer",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ServiceRequest-performer",
                                  "type": "reference"
                                },
                                {
                                  "name": "requester",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ServiceRequest-requester",
                                  "type": "reference"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token",
                                  "documentation": "Logical id of this artifact"
                                }
                              ],
                              "searchRevInclude": [
                                "*"
                              ]
                            },
                            {
                              "type": "MedicationDispense",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/NzPharmacyMedicationDispense"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "identifier",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-identifier",
                                  "type": "token"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/medications-status",
                                  "type": "token"
                                },
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference"
                                },
                                {
                                  "name": "prescription",
                                  "definition": "http://hl7.org/fhir/SearchParameter/MedicationDispense-prescription",
                                  "type": "reference"
                                },
                                {
                                  "name": "whenhandedover",
                                  "definition": "http://hl7.org/fhir/SearchParameter/MedicationDispense-whenhandedover",
                                  "type": "date"
                                },
                                {
                                  "name": "whenprepared",
                                  "definition": "http://hl7.org/fhir/SearchParameter/MedicationDispense-whenprepared",
                                  "type": "date"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token"
                                }
                              ]
                            },
                            {
                              "type": "MedicationRequest",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/NzPharmacyMedicationRequest"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "identifier",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-identifier",
                                  "type": "token"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/medications-status",
                                  "type": "token"
                                },
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference"
                                },
                                {
                                  "name": "subject",
                                  "definition": "http://hl7.org/fhir/SearchParameter/MedicationRequest-subject",
                                  "type": "reference"
                                },
                                {
                                  "name": "requester",
                                  "definition": "http://hl7.org/fhir/SearchParameter/MedicationRequest-requester",
                                  "type": "reference"
                                },
                                {
                                  "name": "authoredon",
                                  "definition": "http://hl7.org/fhir/SearchParameter/MedicationRequest-authoredon",
                                  "type": "date"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token"
                                }
                              ]
                            },
                            {
                              "type": "Claim",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/SharedCareClaim",
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/NzPharmacyClaim"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "identifier",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-identifier",
                                  "type": "token"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Claim-status",
                                  "type": "token"
                                },
                                {
                                  "name": "patient",
                                  "definition": "http://hl7.org/fhir/SearchParameter/clinical-patient",
                                  "type": "reference"
                                },
                                {
                                  "name": "provider",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Claim-provider",
                                  "type": "reference"
                                },
                                {
                                  "name": "created",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Claim-created",
                                  "type": "date"
                                },
                                {
                                  "name": "use",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Claim-use",
                                  "type": "token"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token"
                                }
                              ]
                            },
                            {
                              "type": "ClaimResponse",
                              "supportedProfile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/SharedCareClaimResponse",
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/NzPharmacyClaimResponse"
                              ],
                              "interaction": [
                                {
                                  "code": "create"
                                },
                                {
                                  "code": "read"
                                },
                                {
                                  "code": "update"
                                },
                                {
                                  "code": "delete"
                                },
                                {
                                  "code": "vread"
                                },
                                {
                                  "code": "search-type"
                                }
                              ],
                              "versioning": "versioned",
                              "readHistory": false,
                              "updateCreate": false,
                              "conditionalCreate": false,
                              "conditionalRead": "not-supported",
                              "conditionalUpdate": false,
                              "conditionalDelete": "not-supported",
                              "searchParam": [
                                {
                                  "name": "identifier",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ClaimResponse-identifier",
                                  "type": "token"
                                },
                                {
                                  "name": "status",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ClaimResponse-status",
                                  "type": "token"
                                },
                                {
                                  "name": "request",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ClaimResponse-request",
                                  "type": "reference"
                                },
                                {
                                  "name": "created",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ClaimResponse-created",
                                  "type": "date"
                                },
                                {
                                  "name": "outcome",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ClaimResponse-outcome",
                                  "type": "token"
                                },
                                {
                                  "name": "requestor",
                                  "definition": "http://hl7.org/fhir/SearchParameter/ClaimResponse-requestor",
                                  "type": "reference"
                                },
                                {
                                  "name": "_id",
                                  "definition": "http://hl7.org/fhir/SearchParameter/Resource-id",
                                  "type": "token"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/Appointment/{rid}": {
      "get": {
        "summary": "Read Appointment",
        "description": "Read Appointment",
        "tags": [
          "Appointment"
        ],
        "operationId": "readAppointment",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "description": "Resource id",
            "name": "rid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful read operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "serviceCategory": {
                          "type": "array",
                          "items": {
                            "description": "A broad categorization of the service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "serviceType": {
                          "type": "array",
                          "items": {
                            "description": "The specific service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "specialty": {
                          "type": "array",
                          "items": {
                            "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "appointmentType": {
                          "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "reasonReference": {
                          "type": "array",
                          "items": {
                            "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "priority": {
                          "type": "integer",
                          "format": "int32",
                          "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "supportingInformation": {
                          "type": "array",
                          "items": {
                            "description": "Additional information to support the appointment provided when making the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "minutesDuration": {
                          "type": "integer",
                          "format": "int32",
                          "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "patientInstruction": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                        },
                        "basedOn": {
                          "type": "array",
                          "items": {
                            "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant"
                      ]
                    },
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              },
                              "minItems": 1
                            }
                          },
                          "required": [
                            "source",
                            "tag"
                          ]
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          },
                          "maxItems": 1,
                          "required": [
                            "system",
                            "value"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "minItems": 1
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant",
                        "meta",
                        "reasonCode"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              },
                              "minItems": 1
                            }
                          },
                          "required": [
                            "source",
                            "tag"
                          ]
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          },
                          "minItems": 1
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          },
                          "required": [
                            "value"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "serviceCategory": {
                          "type": "array",
                          "items": {
                            "description": "A broad categorization of the service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "serviceType": {
                          "type": "array",
                          "items": {
                            "description": "The specific service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "specialty": {
                          "type": "array",
                          "items": {
                            "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "appointmentType": {
                          "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "reasonReference": {
                          "type": "array",
                          "items": {
                            "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "priority": {
                          "type": "integer",
                          "format": "int32",
                          "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "supportingInformation": {
                          "type": "array",
                          "items": {
                            "description": "Additional information to support the appointment provided when making the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "minutesDuration": {
                          "type": "integer",
                          "format": "int32",
                          "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "patientInstruction": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                        },
                        "basedOn": {
                          "type": "array",
                          "items": {
                            "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant",
                        "extension"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                    }
                  ]
                },
                "examples": {
                  "Appointment-OnlineGPAppointmentExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "OnlineGPAppointmentExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F12345-A",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                        ]
                      },
                      "participant": [
                        {
                          "actor": {
                            "type": "Patient",
                            "identifier": {
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZZZ0008"
                            }
                          },
                          "status": "accepted"
                        }
                      ],
                      "identifier": [
                        {
                          "use": "official",
                          "system": "https://provider-org-name.co.nz/ns/appointment-identifier",
                          "value": "APT123456"
                        }
                      ],
                      "status": "fulfilled",
                      "created": "2025-01-01T09:30:00+13:00",
                      "start": "2025-01-01T10:00:00+13:00",
                      "end": "2025-01-01T10:17:00+13:00",
                      "reasonCode": [
                        {
                          "coding": [
                            {
                              "code": "266934004",
                              "system": "http://snomed.info/sct",
                              "display": "Transport problem (finding)"
                            }
                          ]
                        }
                      ]
                    }
                  },
                  "Appointment-DHOAppointmentClinicExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentClinicExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "in-person",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "In person"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                        }
                      ],
                      "status": "booked",
                      "description": "DH Fracture Consultant",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "Bring all medications you are currently taking on your admission to hospital.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "ATND",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "attender"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        },
                        {
                          "resourceType": "Slot",
                          "id": "AppointmentSlot",
                          "status": "busy",
                          "start": "2025-09-03T02:30:35Z",
                          "end": "2025-09-03T03:30:35Z",
                          "schedule": {
                            "reference": "#ClinicSchedule"
                          }
                        },
                        {
                          "resourceType": "Schedule",
                          "id": "ClinicSchedule",
                          "identifier": [
                            {
                              "value": "SOFRACONDHZ01"
                            }
                          ],
                          "active": true,
                          "actor": [
                            {
                              "identifier": {
                                "use": "official",
                                "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                                "value": "99ZZZX"
                              },
                              "display": "Dr Dotty McStuffins"
                            }
                          ]
                        }
                      ],
                      "slot": [
                        {
                          "reference": "#AppointmentSlot"
                        }
                      ],
                      "start": "2025-09-03T02:30:35Z",
                      "end": "2025-09-03T03:30:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentTelehealthExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentTelehealthExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "telehealth",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "Telehealth"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
                        }
                      ],
                      "status": "booked",
                      "description": "Telehealth follow-up",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "Please be available at the scheduled time; ensure your device is charged and you have a stable connection.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-10T02:30:35Z",
                      "end": "2025-09-10T03:00:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentTelephoneExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentTelephoneExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "telephone",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "Telephone"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#bbbbbbbb-cccc-dddd-eeee-ffffffffffff"
                        }
                      ],
                      "status": "booked",
                      "description": "Telephone follow-up",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "We will call you at the scheduled time. Please keep your phone nearby and ensure voicemail is enabled.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-17T02:30:35Z",
                      "end": "2025-09-17T02:50:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentUnstructuredExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentUnstructuredExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "in-person",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "In person"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                        }
                      ],
                      "status": "booked",
                      "description": "Physiotherapy Appointment",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "A01",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Allied Health and other"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "A01B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "A01B - Physiotherapy"
                            }
                          ]
                        }
                      ],
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-03T02:30:35Z",
                      "end": "2025-09-03T03:30:35Z"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful read operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful read operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful read operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful read operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/Appointment.r"
            ]
          }
        ]
      },
      "delete": {
        "summary": "Delete Appointment",
        "description": "Delete Appointment",
        "tags": [
          "Appointment"
        ],
        "operationId": "deleteAppointment",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "description": "Resource id",
            "name": "rid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful delete operation",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful delete operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful delete operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful delete operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful delete operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/Appointment.d"
            ]
          }
        ]
      },
      "put": {
        "summary": "Update Appointment",
        "description": "Update Appointment",
        "tags": [
          "Appointment"
        ],
        "operationId": "updateAppointment",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "description": "Resource id",
            "name": "rid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful update operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "serviceCategory": {
                          "type": "array",
                          "items": {
                            "description": "A broad categorization of the service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "serviceType": {
                          "type": "array",
                          "items": {
                            "description": "The specific service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "specialty": {
                          "type": "array",
                          "items": {
                            "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "appointmentType": {
                          "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "reasonReference": {
                          "type": "array",
                          "items": {
                            "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "priority": {
                          "type": "integer",
                          "format": "int32",
                          "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "supportingInformation": {
                          "type": "array",
                          "items": {
                            "description": "Additional information to support the appointment provided when making the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "minutesDuration": {
                          "type": "integer",
                          "format": "int32",
                          "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "patientInstruction": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                        },
                        "basedOn": {
                          "type": "array",
                          "items": {
                            "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant"
                      ]
                    },
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              },
                              "minItems": 1
                            }
                          },
                          "required": [
                            "source",
                            "tag"
                          ]
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          },
                          "maxItems": 1,
                          "required": [
                            "system",
                            "value"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "minItems": 1
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant",
                        "meta",
                        "reasonCode"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              },
                              "minItems": 1
                            }
                          },
                          "required": [
                            "source",
                            "tag"
                          ]
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          },
                          "minItems": 1
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          },
                          "required": [
                            "value"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "serviceCategory": {
                          "type": "array",
                          "items": {
                            "description": "A broad categorization of the service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "serviceType": {
                          "type": "array",
                          "items": {
                            "description": "The specific service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "specialty": {
                          "type": "array",
                          "items": {
                            "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "appointmentType": {
                          "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "reasonReference": {
                          "type": "array",
                          "items": {
                            "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "priority": {
                          "type": "integer",
                          "format": "int32",
                          "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "supportingInformation": {
                          "type": "array",
                          "items": {
                            "description": "Additional information to support the appointment provided when making the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "minutesDuration": {
                          "type": "integer",
                          "format": "int32",
                          "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "patientInstruction": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                        },
                        "basedOn": {
                          "type": "array",
                          "items": {
                            "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant",
                        "extension"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                    }
                  ]
                },
                "examples": {
                  "Appointment-OnlineGPAppointmentExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "OnlineGPAppointmentExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F12345-A",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                        ]
                      },
                      "participant": [
                        {
                          "actor": {
                            "type": "Patient",
                            "identifier": {
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZZZ0008"
                            }
                          },
                          "status": "accepted"
                        }
                      ],
                      "identifier": [
                        {
                          "use": "official",
                          "system": "https://provider-org-name.co.nz/ns/appointment-identifier",
                          "value": "APT123456"
                        }
                      ],
                      "status": "fulfilled",
                      "created": "2025-01-01T09:30:00+13:00",
                      "start": "2025-01-01T10:00:00+13:00",
                      "end": "2025-01-01T10:17:00+13:00",
                      "reasonCode": [
                        {
                          "coding": [
                            {
                              "code": "266934004",
                              "system": "http://snomed.info/sct",
                              "display": "Transport problem (finding)"
                            }
                          ]
                        }
                      ]
                    }
                  },
                  "Appointment-DHOAppointmentClinicExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentClinicExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "in-person",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "In person"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                        }
                      ],
                      "status": "booked",
                      "description": "DH Fracture Consultant",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "Bring all medications you are currently taking on your admission to hospital.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "ATND",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "attender"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        },
                        {
                          "resourceType": "Slot",
                          "id": "AppointmentSlot",
                          "status": "busy",
                          "start": "2025-09-03T02:30:35Z",
                          "end": "2025-09-03T03:30:35Z",
                          "schedule": {
                            "reference": "#ClinicSchedule"
                          }
                        },
                        {
                          "resourceType": "Schedule",
                          "id": "ClinicSchedule",
                          "identifier": [
                            {
                              "value": "SOFRACONDHZ01"
                            }
                          ],
                          "active": true,
                          "actor": [
                            {
                              "identifier": {
                                "use": "official",
                                "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                                "value": "99ZZZX"
                              },
                              "display": "Dr Dotty McStuffins"
                            }
                          ]
                        }
                      ],
                      "slot": [
                        {
                          "reference": "#AppointmentSlot"
                        }
                      ],
                      "start": "2025-09-03T02:30:35Z",
                      "end": "2025-09-03T03:30:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentTelehealthExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentTelehealthExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "telehealth",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "Telehealth"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
                        }
                      ],
                      "status": "booked",
                      "description": "Telehealth follow-up",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "Please be available at the scheduled time; ensure your device is charged and you have a stable connection.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-10T02:30:35Z",
                      "end": "2025-09-10T03:00:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentTelephoneExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentTelephoneExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "telephone",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "Telephone"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#bbbbbbbb-cccc-dddd-eeee-ffffffffffff"
                        }
                      ],
                      "status": "booked",
                      "description": "Telephone follow-up",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "We will call you at the scheduled time. Please keep your phone nearby and ensure voicemail is enabled.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-17T02:30:35Z",
                      "end": "2025-09-17T02:50:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentUnstructuredExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentUnstructuredExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "in-person",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "In person"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                        }
                      ],
                      "status": "booked",
                      "description": "Physiotherapy Appointment",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "A01",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Allied Health and other"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "A01B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "A01B - Physiotherapy"
                            }
                          ]
                        }
                      ],
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-03T02:30:35Z",
                      "end": "2025-09-03T03:30:35Z"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful update operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful update operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful update operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful update operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "requestBody": {
          "description": "Appointment to create",
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "resourceType": {
                        "type": "string",
                        "enum": [
                          "Appointment"
                        ]
                      },
                      "id": {
                        "type": "string",
                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                        "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                      },
                      "meta": {
                        "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                        "type": "object",
                        "properties": {
                          "versionId": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                          },
                          "lastUpdated": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                            "description": "When the resource last changed &ndash; e.g. when the version changed."
                          },
                          "source": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                          },
                          "profile": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                            }
                          },
                          "security": {
                            "type": "array",
                            "items": {
                              "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "tag": {
                            "type": "array",
                            "items": {
                              "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          }
                        }
                      },
                      "implicitRules": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                      },
                      "language": {
                        "type": "string",
                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                        "description": "The base language in which the resource is written."
                      },
                      "text": {
                        "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                        "type": "object",
                        "properties": {
                          "status": {
                            "type": "string",
                            "enum": [
                              "generated",
                              "extensions",
                              "additional",
                              "empty"
                            ],
                            "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                          },
                          "div": {
                            "type": "string",
                            "description": "The actual narrative content, a stripped down version of XHTML."
                          }
                        },
                        "required": [
                          "status",
                          "div"
                        ]
                      },
                      "contained": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "resourceType": {
                              "type": "string",
                              "enum": [
                                "Account",
                                "ActivityDefinition",
                                "AdverseEvent",
                                "AllergyIntolerance",
                                "Appointment",
                                "AppointmentResponse",
                                "AuditEvent",
                                "Basic",
                                "Binary",
                                "BiologicallyDerivedProduct",
                                "BodyStructure",
                                "Bundle",
                                "CapabilityStatement",
                                "CarePlan",
                                "CareTeam",
                                "CatalogEntry",
                                "ChargeItem",
                                "ChargeItemDefinition",
                                "Claim",
                                "ClaimResponse",
                                "ClinicalImpression",
                                "CodeSystem",
                                "Communication",
                                "CommunicationRequest",
                                "CompartmentDefinition",
                                "Composition",
                                "ConceptMap",
                                "Condition",
                                "Consent",
                                "Contract",
                                "Coverage",
                                "CoverageEligibilityRequest",
                                "CoverageEligibilityResponse",
                                "DetectedIssue",
                                "Device",
                                "DeviceDefinition",
                                "DeviceMetric",
                                "DeviceRequest",
                                "DeviceUseStatement",
                                "DiagnosticReport",
                                "DocumentManifest",
                                "DocumentReference",
                                "DomainResource",
                                "EffectEvidenceSynthesis",
                                "Encounter",
                                "Endpoint",
                                "EnrollmentRequest",
                                "EnrollmentResponse",
                                "EpisodeOfCare",
                                "EventDefinition",
                                "Evidence",
                                "EvidenceVariable",
                                "ExampleScenario",
                                "ExplanationOfBenefit",
                                "FamilyMemberHistory",
                                "Flag",
                                "Goal",
                                "GraphDefinition",
                                "Group",
                                "GuidanceResponse",
                                "HealthcareService",
                                "ImagingStudy",
                                "Immunization",
                                "ImmunizationEvaluation",
                                "ImmunizationRecommendation",
                                "ImplementationGuide",
                                "InsurancePlan",
                                "Invoice",
                                "Library",
                                "Linkage",
                                "List",
                                "Location",
                                "Measure",
                                "MeasureReport",
                                "Media",
                                "Medication",
                                "MedicationAdministration",
                                "MedicationDispense",
                                "MedicationKnowledge",
                                "MedicationRequest",
                                "MedicationStatement",
                                "MedicinalProduct",
                                "MedicinalProductAuthorization",
                                "MedicinalProductContraindication",
                                "MedicinalProductIndication",
                                "MedicinalProductIngredient",
                                "MedicinalProductInteraction",
                                "MedicinalProductManufactured",
                                "MedicinalProductPackaged",
                                "MedicinalProductPharmaceutical",
                                "MedicinalProductUndesirableEffect",
                                "MessageDefinition",
                                "MessageHeader",
                                "MolecularSequence",
                                "NamingSystem",
                                "NutritionOrder",
                                "Observation",
                                "ObservationDefinition",
                                "OperationDefinition",
                                "OperationOutcome",
                                "Organization",
                                "OrganizationAffiliation",
                                "Parameters",
                                "Patient",
                                "PaymentNotice",
                                "PaymentReconciliation",
                                "Person",
                                "PlanDefinition",
                                "Practitioner",
                                "PractitionerRole",
                                "Procedure",
                                "Provenance",
                                "Questionnaire",
                                "QuestionnaireResponse",
                                "RelatedPerson",
                                "RequestGroup",
                                "ResearchDefinition",
                                "ResearchElementDefinition",
                                "ResearchStudy",
                                "ResearchSubject",
                                "Resource",
                                "RiskAssessment",
                                "RiskEvidenceSynthesis",
                                "Schedule",
                                "SearchParameter",
                                "ServiceRequest",
                                "Slot",
                                "Specimen",
                                "SpecimenDefinition",
                                "StructureDefinition",
                                "StructureMap",
                                "Subscription",
                                "Substance",
                                "SubstanceNucleicAcid",
                                "SubstancePolymer",
                                "SubstanceProtein",
                                "SubstanceReferenceInformation",
                                "SubstanceSourceMaterial",
                                "SubstanceSpecification",
                                "SupplyDelivery",
                                "SupplyRequest",
                                "Task",
                                "TerminologyCapabilities",
                                "TestReport",
                                "TestScript",
                                "ValueSet",
                                "VerificationResult",
                                "VisionPrescription"
                              ]
                            },
                            "id": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                            },
                            "meta": {
                              "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                              "type": "object",
                              "properties": {
                                "versionId": {
                                  "type": "string",
                                  "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                  "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                },
                                "lastUpdated": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                  "description": "When the resource last changed &ndash; e.g. when the version changed."
                                },
                                "source": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                },
                                "profile": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                  }
                                },
                                "security": {
                                  "type": "array",
                                  "items": {
                                    "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "tag": {
                                  "type": "array",
                                  "items": {
                                    "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                }
                              }
                            },
                            "implicitRules": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                            },
                            "language": {
                              "type": "string",
                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                              "description": "The base language in which the resource is written."
                            }
                          },
                          "required": [
                            "resourceType"
                          ],
                          "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                        }
                      },
                      "extension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "modifierExtension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "identifier": {
                        "type": "array",
                        "items": {
                          "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                          "type": "object",
                          "properties": {
                            "use": {
                              "type": "string",
                              "enum": [
                                "usual",
                                "official",
                                "temp",
                                "secondary",
                                "old"
                              ],
                              "description": "The purpose of this identifier."
                            },
                            "type": {
                              "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                            },
                            "value": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                            },
                            "period": {
                              "description": "Time period during which identifier is/was valid for use.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            },
                            "assigner": {
                              "description": "Organization that issued/manages the identifier.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            }
                          }
                        }
                      },
                      "status": {
                        "type": "string",
                        "enum": [
                          "proposed",
                          "pending",
                          "booked",
                          "arrived",
                          "fulfilled",
                          "cancelled",
                          "noshow",
                          "entered-in-error",
                          "checked-in",
                          "waitlist"
                        ],
                        "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                      },
                      "cancelationReason": {
                        "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "serviceCategory": {
                        "type": "array",
                        "items": {
                          "description": "A broad categorization of the service that is to be performed during this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "serviceType": {
                        "type": "array",
                        "items": {
                          "description": "The specific service that is to be performed during this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "specialty": {
                        "type": "array",
                        "items": {
                          "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "appointmentType": {
                        "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "reasonCode": {
                        "type": "array",
                        "items": {
                          "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "reasonReference": {
                        "type": "array",
                        "items": {
                          "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "priority": {
                        "type": "integer",
                        "format": "int32",
                        "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                      },
                      "description": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                      },
                      "supportingInformation": {
                        "type": "array",
                        "items": {
                          "description": "Additional information to support the appointment provided when making the appointment.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "start": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to take place."
                      },
                      "end": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to conclude."
                      },
                      "minutesDuration": {
                        "type": "integer",
                        "format": "int32",
                        "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                      },
                      "slot": {
                        "type": "array",
                        "items": {
                          "description": "The slots from the participants' schedules that will be filled by the appointment.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "created": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                        "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                      },
                      "comment": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "Additional comments about the appointment."
                      },
                      "patientInstruction": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                      },
                      "basedOn": {
                        "type": "array",
                        "items": {
                          "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "participant": {
                        "type": "array",
                        "items": {
                          "description": "List of participants involved in the appointment.",
                          "type": "object",
                          "properties": {
                            "modifierExtension": {
                              "type": "array",
                              "items": {
                                "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                "type": "object",
                                "additionalProperties": true
                              }
                            },
                            "type": {
                              "type": "array",
                              "items": {
                                "description": "Role of participant in the appointment.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              }
                            },
                            "actor": {
                              "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            },
                            "required": {
                              "type": "string",
                              "enum": [
                                "required",
                                "optional",
                                "information-only"
                              ],
                              "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                            },
                            "status": {
                              "type": "string",
                              "enum": [
                                "accepted",
                                "declined",
                                "tentative",
                                "needs-action"
                              ],
                              "description": "Participation status of the actor."
                            },
                            "period": {
                              "description": "Participation period of the actor.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            }
                          },
                          "required": [
                            "status"
                          ]
                        },
                        "minItems": 1
                      },
                      "requestedPeriod": {
                        "type": "array",
                        "items": {
                          "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        }
                      }
                    },
                    "required": [
                      "resourceType",
                      "status",
                      "participant"
                    ]
                  },
                  {
                    "type": "object",
                    "properties": {
                      "resourceType": {
                        "type": "string",
                        "enum": [
                          "Appointment"
                        ]
                      },
                      "id": {
                        "type": "string",
                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                        "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                      },
                      "meta": {
                        "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                        "type": "object",
                        "properties": {
                          "versionId": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                          },
                          "lastUpdated": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                            "description": "When the resource last changed &ndash; e.g. when the version changed."
                          },
                          "source": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                          },
                          "profile": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                            }
                          },
                          "security": {
                            "type": "array",
                            "items": {
                              "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "tag": {
                            "type": "array",
                            "items": {
                              "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            },
                            "minItems": 1
                          }
                        },
                        "required": [
                          "source",
                          "tag"
                        ]
                      },
                      "implicitRules": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                      },
                      "language": {
                        "type": "string",
                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                        "description": "The base language in which the resource is written."
                      },
                      "text": {
                        "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                        "type": "object",
                        "properties": {
                          "status": {
                            "type": "string",
                            "enum": [
                              "generated",
                              "extensions",
                              "additional",
                              "empty"
                            ],
                            "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                          },
                          "div": {
                            "type": "string",
                            "description": "The actual narrative content, a stripped down version of XHTML."
                          }
                        },
                        "required": [
                          "status",
                          "div"
                        ]
                      },
                      "extension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "modifierExtension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "identifier": {
                        "type": "array",
                        "items": {
                          "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                          "type": "object",
                          "properties": {
                            "use": {
                              "type": "string",
                              "enum": [
                                "usual",
                                "official",
                                "temp",
                                "secondary",
                                "old"
                              ],
                              "description": "The purpose of this identifier."
                            },
                            "type": {
                              "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                            },
                            "value": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                            },
                            "period": {
                              "description": "Time period during which identifier is/was valid for use.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            },
                            "assigner": {
                              "description": "Organization that issued/manages the identifier.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            }
                          }
                        },
                        "maxItems": 1,
                        "required": [
                          "system",
                          "value"
                        ]
                      },
                      "status": {
                        "type": "string",
                        "enum": [
                          "proposed",
                          "pending",
                          "booked",
                          "arrived",
                          "fulfilled",
                          "cancelled",
                          "noshow",
                          "entered-in-error",
                          "checked-in",
                          "waitlist"
                        ],
                        "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                      },
                      "cancelationReason": {
                        "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "reasonCode": {
                        "type": "array",
                        "items": {
                          "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "minItems": 1
                      },
                      "description": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                      },
                      "start": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to take place."
                      },
                      "end": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to conclude."
                      },
                      "slot": {
                        "type": "array",
                        "items": {
                          "description": "The slots from the participants' schedules that will be filled by the appointment.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "created": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                        "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                      },
                      "comment": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "Additional comments about the appointment."
                      },
                      "participant": {
                        "type": "array",
                        "items": {
                          "description": "List of participants involved in the appointment.",
                          "type": "object",
                          "properties": {
                            "modifierExtension": {
                              "type": "array",
                              "items": {
                                "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                "type": "object",
                                "additionalProperties": true
                              }
                            },
                            "type": {
                              "type": "array",
                              "items": {
                                "description": "Role of participant in the appointment.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              }
                            },
                            "actor": {
                              "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            },
                            "required": {
                              "type": "string",
                              "enum": [
                                "required",
                                "optional",
                                "information-only"
                              ],
                              "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                            },
                            "status": {
                              "type": "string",
                              "enum": [
                                "accepted",
                                "declined",
                                "tentative",
                                "needs-action"
                              ],
                              "description": "Participation status of the actor."
                            },
                            "period": {
                              "description": "Participation period of the actor.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            }
                          },
                          "required": [
                            "status"
                          ]
                        },
                        "minItems": 1
                      },
                      "requestedPeriod": {
                        "type": "array",
                        "items": {
                          "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        }
                      }
                    },
                    "required": [
                      "resourceType",
                      "status",
                      "participant",
                      "meta",
                      "reasonCode"
                    ],
                    "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                  },
                  {
                    "type": "object",
                    "properties": {
                      "resourceType": {
                        "type": "string",
                        "enum": [
                          "Appointment"
                        ]
                      },
                      "id": {
                        "type": "string",
                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                        "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                      },
                      "meta": {
                        "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                        "type": "object",
                        "properties": {
                          "versionId": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                          },
                          "lastUpdated": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                            "description": "When the resource last changed &ndash; e.g. when the version changed."
                          },
                          "source": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                          },
                          "profile": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                            }
                          },
                          "security": {
                            "type": "array",
                            "items": {
                              "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "tag": {
                            "type": "array",
                            "items": {
                              "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            },
                            "minItems": 1
                          }
                        },
                        "required": [
                          "source",
                          "tag"
                        ]
                      },
                      "implicitRules": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                      },
                      "language": {
                        "type": "string",
                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                        "description": "The base language in which the resource is written."
                      },
                      "text": {
                        "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                        "type": "object",
                        "properties": {
                          "status": {
                            "type": "string",
                            "enum": [
                              "generated",
                              "extensions",
                              "additional",
                              "empty"
                            ],
                            "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                          },
                          "div": {
                            "type": "string",
                            "description": "The actual narrative content, a stripped down version of XHTML."
                          }
                        },
                        "required": [
                          "status",
                          "div"
                        ]
                      },
                      "contained": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "resourceType": {
                              "type": "string",
                              "enum": [
                                "Account",
                                "ActivityDefinition",
                                "AdverseEvent",
                                "AllergyIntolerance",
                                "Appointment",
                                "AppointmentResponse",
                                "AuditEvent",
                                "Basic",
                                "Binary",
                                "BiologicallyDerivedProduct",
                                "BodyStructure",
                                "Bundle",
                                "CapabilityStatement",
                                "CarePlan",
                                "CareTeam",
                                "CatalogEntry",
                                "ChargeItem",
                                "ChargeItemDefinition",
                                "Claim",
                                "ClaimResponse",
                                "ClinicalImpression",
                                "CodeSystem",
                                "Communication",
                                "CommunicationRequest",
                                "CompartmentDefinition",
                                "Composition",
                                "ConceptMap",
                                "Condition",
                                "Consent",
                                "Contract",
                                "Coverage",
                                "CoverageEligibilityRequest",
                                "CoverageEligibilityResponse",
                                "DetectedIssue",
                                "Device",
                                "DeviceDefinition",
                                "DeviceMetric",
                                "DeviceRequest",
                                "DeviceUseStatement",
                                "DiagnosticReport",
                                "DocumentManifest",
                                "DocumentReference",
                                "DomainResource",
                                "EffectEvidenceSynthesis",
                                "Encounter",
                                "Endpoint",
                                "EnrollmentRequest",
                                "EnrollmentResponse",
                                "EpisodeOfCare",
                                "EventDefinition",
                                "Evidence",
                                "EvidenceVariable",
                                "ExampleScenario",
                                "ExplanationOfBenefit",
                                "FamilyMemberHistory",
                                "Flag",
                                "Goal",
                                "GraphDefinition",
                                "Group",
                                "GuidanceResponse",
                                "HealthcareService",
                                "ImagingStudy",
                                "Immunization",
                                "ImmunizationEvaluation",
                                "ImmunizationRecommendation",
                                "ImplementationGuide",
                                "InsurancePlan",
                                "Invoice",
                                "Library",
                                "Linkage",
                                "List",
                                "Location",
                                "Measure",
                                "MeasureReport",
                                "Media",
                                "Medication",
                                "MedicationAdministration",
                                "MedicationDispense",
                                "MedicationKnowledge",
                                "MedicationRequest",
                                "MedicationStatement",
                                "MedicinalProduct",
                                "MedicinalProductAuthorization",
                                "MedicinalProductContraindication",
                                "MedicinalProductIndication",
                                "MedicinalProductIngredient",
                                "MedicinalProductInteraction",
                                "MedicinalProductManufactured",
                                "MedicinalProductPackaged",
                                "MedicinalProductPharmaceutical",
                                "MedicinalProductUndesirableEffect",
                                "MessageDefinition",
                                "MessageHeader",
                                "MolecularSequence",
                                "NamingSystem",
                                "NutritionOrder",
                                "Observation",
                                "ObservationDefinition",
                                "OperationDefinition",
                                "OperationOutcome",
                                "Organization",
                                "OrganizationAffiliation",
                                "Parameters",
                                "Patient",
                                "PaymentNotice",
                                "PaymentReconciliation",
                                "Person",
                                "PlanDefinition",
                                "Practitioner",
                                "PractitionerRole",
                                "Procedure",
                                "Provenance",
                                "Questionnaire",
                                "QuestionnaireResponse",
                                "RelatedPerson",
                                "RequestGroup",
                                "ResearchDefinition",
                                "ResearchElementDefinition",
                                "ResearchStudy",
                                "ResearchSubject",
                                "Resource",
                                "RiskAssessment",
                                "RiskEvidenceSynthesis",
                                "Schedule",
                                "SearchParameter",
                                "ServiceRequest",
                                "Slot",
                                "Specimen",
                                "SpecimenDefinition",
                                "StructureDefinition",
                                "StructureMap",
                                "Subscription",
                                "Substance",
                                "SubstanceNucleicAcid",
                                "SubstancePolymer",
                                "SubstanceProtein",
                                "SubstanceReferenceInformation",
                                "SubstanceSourceMaterial",
                                "SubstanceSpecification",
                                "SupplyDelivery",
                                "SupplyRequest",
                                "Task",
                                "TerminologyCapabilities",
                                "TestReport",
                                "TestScript",
                                "ValueSet",
                                "VerificationResult",
                                "VisionPrescription"
                              ]
                            },
                            "id": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                            },
                            "meta": {
                              "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                              "type": "object",
                              "properties": {
                                "versionId": {
                                  "type": "string",
                                  "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                  "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                },
                                "lastUpdated": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                  "description": "When the resource last changed &ndash; e.g. when the version changed."
                                },
                                "source": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                },
                                "profile": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                  }
                                },
                                "security": {
                                  "type": "array",
                                  "items": {
                                    "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "tag": {
                                  "type": "array",
                                  "items": {
                                    "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                }
                              }
                            },
                            "implicitRules": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                            },
                            "language": {
                              "type": "string",
                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                              "description": "The base language in which the resource is written."
                            }
                          },
                          "required": [
                            "resourceType"
                          ],
                          "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                        }
                      },
                      "extension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                          "type": "object",
                          "additionalProperties": true
                        },
                        "minItems": 1
                      },
                      "modifierExtension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "identifier": {
                        "type": "array",
                        "items": {
                          "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                          "type": "object",
                          "properties": {
                            "use": {
                              "type": "string",
                              "enum": [
                                "usual",
                                "official",
                                "temp",
                                "secondary",
                                "old"
                              ],
                              "description": "The purpose of this identifier."
                            },
                            "type": {
                              "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                            },
                            "value": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                            },
                            "period": {
                              "description": "Time period during which identifier is/was valid for use.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            },
                            "assigner": {
                              "description": "Organization that issued/manages the identifier.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            }
                          }
                        },
                        "required": [
                          "value"
                        ]
                      },
                      "status": {
                        "type": "string",
                        "enum": [
                          "proposed",
                          "pending",
                          "booked",
                          "arrived",
                          "fulfilled",
                          "cancelled",
                          "noshow",
                          "entered-in-error",
                          "checked-in",
                          "waitlist"
                        ],
                        "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                      },
                      "cancelationReason": {
                        "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "serviceCategory": {
                        "type": "array",
                        "items": {
                          "description": "A broad categorization of the service that is to be performed during this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "serviceType": {
                        "type": "array",
                        "items": {
                          "description": "The specific service that is to be performed during this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "specialty": {
                        "type": "array",
                        "items": {
                          "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "appointmentType": {
                        "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "reasonCode": {
                        "type": "array",
                        "items": {
                          "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "reasonReference": {
                        "type": "array",
                        "items": {
                          "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "priority": {
                        "type": "integer",
                        "format": "int32",
                        "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                      },
                      "description": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                      },
                      "supportingInformation": {
                        "type": "array",
                        "items": {
                          "description": "Additional information to support the appointment provided when making the appointment.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "start": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to take place."
                      },
                      "end": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to conclude."
                      },
                      "minutesDuration": {
                        "type": "integer",
                        "format": "int32",
                        "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                      },
                      "slot": {
                        "type": "array",
                        "items": {
                          "description": "The slots from the participants' schedules that will be filled by the appointment.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "created": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                        "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                      },
                      "comment": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "Additional comments about the appointment."
                      },
                      "patientInstruction": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                      },
                      "basedOn": {
                        "type": "array",
                        "items": {
                          "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "participant": {
                        "type": "array",
                        "items": {
                          "description": "List of participants involved in the appointment.",
                          "type": "object",
                          "properties": {
                            "modifierExtension": {
                              "type": "array",
                              "items": {
                                "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                "type": "object",
                                "additionalProperties": true
                              }
                            },
                            "type": {
                              "type": "array",
                              "items": {
                                "description": "Role of participant in the appointment.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              }
                            },
                            "actor": {
                              "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            },
                            "required": {
                              "type": "string",
                              "enum": [
                                "required",
                                "optional",
                                "information-only"
                              ],
                              "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                            },
                            "status": {
                              "type": "string",
                              "enum": [
                                "accepted",
                                "declined",
                                "tentative",
                                "needs-action"
                              ],
                              "description": "Participation status of the actor."
                            },
                            "period": {
                              "description": "Participation period of the actor.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            }
                          },
                          "required": [
                            "status"
                          ]
                        },
                        "minItems": 1
                      },
                      "requestedPeriod": {
                        "type": "array",
                        "items": {
                          "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        }
                      }
                    },
                    "required": [
                      "resourceType",
                      "status",
                      "participant",
                      "extension"
                    ],
                    "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                  }
                ]
              },
              "examples": {
                "Appointment-OnlineGPAppointmentExample": {
                  "value": {
                    "resourceType": "Appointment",
                    "id": "OnlineGPAppointmentExample",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F12345-A",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                      ]
                    },
                    "participant": [
                      {
                        "actor": {
                          "type": "Patient",
                          "identifier": {
                            "system": "https://standards.digital.health.nz/ns/nhi-id",
                            "value": "ZZZ0008"
                          }
                        },
                        "status": "accepted"
                      }
                    ],
                    "identifier": [
                      {
                        "use": "official",
                        "system": "https://provider-org-name.co.nz/ns/appointment-identifier",
                        "value": "APT123456"
                      }
                    ],
                    "status": "fulfilled",
                    "created": "2025-01-01T09:30:00+13:00",
                    "start": "2025-01-01T10:00:00+13:00",
                    "end": "2025-01-01T10:17:00+13:00",
                    "reasonCode": [
                      {
                        "coding": [
                          {
                            "code": "266934004",
                            "system": "http://snomed.info/sct",
                            "display": "Transport problem (finding)"
                          }
                        ]
                      }
                    ]
                  }
                },
                "Appointment-DHOAppointmentClinicExample": {
                  "value": {
                    "resourceType": "Appointment",
                    "id": "DHOAppointmentClinicExample",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "lastUpdated": "2025-11-11T02:29:24.844Z",
                      "versionId": "3",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                    },
                    "extension": [
                      {
                        "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                        "valueCodeableConcept": {
                          "coding": [
                            {
                              "code": "in-person",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                              "display": "In person"
                            }
                          ]
                        }
                      }
                    ],
                    "identifier": [
                      {
                        "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                      }
                    ],
                    "status": "booked",
                    "description": "DH Fracture Consultant",
                    "serviceCategory": [
                      {
                        "coding": [
                          {
                            "code": "S45",
                            "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                            "display": "Orthopaedic Surgery"
                          }
                        ]
                      }
                    ],
                    "serviceType": [
                      {
                        "coding": [
                          {
                            "code": "S45B",
                            "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                            "display": "S45B - Fracture Clinic"
                          }
                        ]
                      }
                    ],
                    "patientInstruction": "Bring all medications you are currently taking on your admission to hospital.",
                    "participant": [
                      {
                        "required": "required",
                        "status": "needs-action",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/nhi-id",
                            "value": "ZXP7823"
                          },
                          "display": "Carey Carrington"
                        }
                      },
                      {
                        "type": [
                          {
                            "coding": [
                              {
                                "code": "ATND",
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                "display": "attender"
                              }
                            ]
                          }
                        ],
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                            "value": "99ZZZX"
                          },
                          "display": "Dr Dotty McStuffins"
                        }
                      },
                      {
                        "type": [
                          {
                            "coding": [
                              {
                                "code": "CON",
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                "display": "consultant"
                              }
                            ]
                          }
                        ],
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                            "value": "99ZZZX"
                          },
                          "display": "Dr Dotty McStuffins"
                        }
                      },
                      {
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "reference": "#DHOClinicLocation"
                        }
                      }
                    ],
                    "contained": [
                      {
                        "resourceType": "Location",
                        "id": "DHOClinicLocation",
                        "meta": {
                          "profile": [
                            "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                          ]
                        },
                        "identifier": [
                          {
                            "value": "4211-K01"
                          }
                        ],
                        "name": "Dunedin Hospital Outpatients, Clinic K01",
                        "partOf": {
                          "type": "Location",
                          "identifier": {
                            "value": "4211",
                            "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                          },
                          "display": "Dunedin Hospital"
                        },
                        "address": {
                          "use": "work",
                          "type": "physical",
                          "line": [
                            "350 Cumberland Street",
                            "Dunedin Central"
                          ],
                          "city": "Dunedin",
                          "postalCode": "9016",
                          "country": "New Zealand"
                        }
                      },
                      {
                        "resourceType": "Slot",
                        "id": "AppointmentSlot",
                        "status": "busy",
                        "start": "2025-09-03T02:30:35Z",
                        "end": "2025-09-03T03:30:35Z",
                        "schedule": {
                          "reference": "#ClinicSchedule"
                        }
                      },
                      {
                        "resourceType": "Schedule",
                        "id": "ClinicSchedule",
                        "identifier": [
                          {
                            "value": "SOFRACONDHZ01"
                          }
                        ],
                        "active": true,
                        "actor": [
                          {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        ]
                      }
                    ],
                    "slot": [
                      {
                        "reference": "#AppointmentSlot"
                      }
                    ],
                    "start": "2025-09-03T02:30:35Z",
                    "end": "2025-09-03T03:30:35Z"
                  }
                },
                "Appointment-DHOAppointmentTelehealthExample": {
                  "value": {
                    "resourceType": "Appointment",
                    "id": "DHOAppointmentTelehealthExample",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "lastUpdated": "2025-11-11T02:29:24.844Z",
                      "versionId": "3",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                    },
                    "extension": [
                      {
                        "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                        "valueCodeableConcept": {
                          "coding": [
                            {
                              "code": "telehealth",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                              "display": "Telehealth"
                            }
                          ]
                        }
                      }
                    ],
                    "identifier": [
                      {
                        "value": "#aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
                      }
                    ],
                    "status": "booked",
                    "description": "Telehealth follow-up",
                    "serviceCategory": [
                      {
                        "coding": [
                          {
                            "code": "S45",
                            "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                            "display": "Orthopaedic Surgery"
                          }
                        ]
                      }
                    ],
                    "serviceType": [
                      {
                        "coding": [
                          {
                            "code": "S45B",
                            "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                            "display": "S45B - Fracture Clinic"
                          }
                        ]
                      }
                    ],
                    "patientInstruction": "Please be available at the scheduled time; ensure your device is charged and you have a stable connection.",
                    "participant": [
                      {
                        "required": "required",
                        "status": "needs-action",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/nhi-id",
                            "value": "ZXP7823"
                          },
                          "display": "Carey Carrington"
                        }
                      },
                      {
                        "type": [
                          {
                            "coding": [
                              {
                                "code": "CON",
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                "display": "consultant"
                              }
                            ]
                          }
                        ],
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                            "value": "99ZZZX"
                          },
                          "display": "Dr Dotty McStuffins"
                        }
                      },
                      {
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "reference": "#DHOClinicLocation"
                        }
                      }
                    ],
                    "contained": [
                      {
                        "resourceType": "Location",
                        "id": "DHOClinicLocation",
                        "meta": {
                          "profile": [
                            "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                          ]
                        },
                        "identifier": [
                          {
                            "value": "4211-K01"
                          }
                        ],
                        "name": "Dunedin Hospital Outpatients, Clinic K01",
                        "partOf": {
                          "type": "Location",
                          "identifier": {
                            "value": "4211",
                            "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                          },
                          "display": "Dunedin Hospital"
                        },
                        "address": {
                          "use": "work",
                          "type": "physical",
                          "line": [
                            "350 Cumberland Street",
                            "Dunedin Central"
                          ],
                          "city": "Dunedin",
                          "postalCode": "9016",
                          "country": "New Zealand"
                        }
                      }
                    ],
                    "start": "2025-09-10T02:30:35Z",
                    "end": "2025-09-10T03:00:35Z"
                  }
                },
                "Appointment-DHOAppointmentTelephoneExample": {
                  "value": {
                    "resourceType": "Appointment",
                    "id": "DHOAppointmentTelephoneExample",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "lastUpdated": "2025-11-11T02:29:24.844Z",
                      "versionId": "3",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                    },
                    "extension": [
                      {
                        "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                        "valueCodeableConcept": {
                          "coding": [
                            {
                              "code": "telephone",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                              "display": "Telephone"
                            }
                          ]
                        }
                      }
                    ],
                    "identifier": [
                      {
                        "value": "#bbbbbbbb-cccc-dddd-eeee-ffffffffffff"
                      }
                    ],
                    "status": "booked",
                    "description": "Telephone follow-up",
                    "serviceCategory": [
                      {
                        "coding": [
                          {
                            "code": "S45",
                            "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                            "display": "Orthopaedic Surgery"
                          }
                        ]
                      }
                    ],
                    "serviceType": [
                      {
                        "coding": [
                          {
                            "code": "S45B",
                            "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                            "display": "S45B - Fracture Clinic"
                          }
                        ]
                      }
                    ],
                    "patientInstruction": "We will call you at the scheduled time. Please keep your phone nearby and ensure voicemail is enabled.",
                    "participant": [
                      {
                        "required": "required",
                        "status": "needs-action",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/nhi-id",
                            "value": "ZXP7823"
                          },
                          "display": "Carey Carrington"
                        }
                      },
                      {
                        "type": [
                          {
                            "coding": [
                              {
                                "code": "CON",
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                "display": "consultant"
                              }
                            ]
                          }
                        ],
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                            "value": "99ZZZX"
                          },
                          "display": "Dr Dotty McStuffins"
                        }
                      },
                      {
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "reference": "#DHOClinicLocation"
                        }
                      }
                    ],
                    "contained": [
                      {
                        "resourceType": "Location",
                        "id": "DHOClinicLocation",
                        "meta": {
                          "profile": [
                            "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                          ]
                        },
                        "identifier": [
                          {
                            "value": "4211-K01"
                          }
                        ],
                        "name": "Dunedin Hospital Outpatients, Clinic K01",
                        "partOf": {
                          "type": "Location",
                          "identifier": {
                            "value": "4211",
                            "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                          },
                          "display": "Dunedin Hospital"
                        },
                        "address": {
                          "use": "work",
                          "type": "physical",
                          "line": [
                            "350 Cumberland Street",
                            "Dunedin Central"
                          ],
                          "city": "Dunedin",
                          "postalCode": "9016",
                          "country": "New Zealand"
                        }
                      }
                    ],
                    "start": "2025-09-17T02:30:35Z",
                    "end": "2025-09-17T02:50:35Z"
                  }
                },
                "Appointment-DHOAppointmentUnstructuredExample": {
                  "value": {
                    "resourceType": "Appointment",
                    "id": "DHOAppointmentUnstructuredExample",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "lastUpdated": "2025-11-11T02:29:24.844Z",
                      "versionId": "3",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                    },
                    "extension": [
                      {
                        "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                        "valueCodeableConcept": {
                          "coding": [
                            {
                              "code": "in-person",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                              "display": "In person"
                            }
                          ]
                        }
                      }
                    ],
                    "identifier": [
                      {
                        "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                      }
                    ],
                    "status": "booked",
                    "description": "Physiotherapy Appointment",
                    "serviceCategory": [
                      {
                        "coding": [
                          {
                            "code": "A01",
                            "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                            "display": "Allied Health and other"
                          }
                        ]
                      }
                    ],
                    "serviceType": [
                      {
                        "coding": [
                          {
                            "code": "A01B",
                            "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                            "display": "A01B - Physiotherapy"
                          }
                        ]
                      }
                    ],
                    "participant": [
                      {
                        "required": "required",
                        "status": "needs-action",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/nhi-id",
                            "value": "ZXP7823"
                          },
                          "display": "Carey Carrington"
                        }
                      },
                      {
                        "type": [
                          {
                            "coding": [
                              {
                                "code": "CON",
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                "display": "consultant"
                              }
                            ]
                          }
                        ],
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                            "value": "99ZZZX"
                          },
                          "display": "Dr Dotty McStuffins"
                        }
                      },
                      {
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "reference": "#DHOClinicLocation"
                        }
                      }
                    ],
                    "contained": [
                      {
                        "resourceType": "Location",
                        "id": "DHOClinicLocation",
                        "meta": {
                          "profile": [
                            "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                          ]
                        },
                        "identifier": [
                          {
                            "value": "4211-K01"
                          }
                        ],
                        "name": "Dunedin Hospital Outpatients, Clinic K01",
                        "partOf": {
                          "type": "Location",
                          "identifier": {
                            "value": "4211",
                            "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                          },
                          "display": "Dunedin Hospital"
                        },
                        "address": {
                          "use": "work",
                          "type": "physical",
                          "line": [
                            "350 Cumberland Street",
                            "Dunedin Central"
                          ],
                          "city": "Dunedin",
                          "postalCode": "9016",
                          "country": "New Zealand"
                        }
                      }
                    ],
                    "start": "2025-09-03T02:30:35Z",
                    "end": "2025-09-03T03:30:35Z"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/Appointment.u"
            ]
          }
        ]
      }
    },
    "/Appointment/{rid}/_history/{vid}": {
      "get": {
        "summary": "Read Appointment (versioned)",
        "description": "Read Appointment (versioned)",
        "tags": [
          "Appointment"
        ],
        "operationId": "vreadAppointment",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "description": "Resource id",
            "name": "rid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Resource version id",
            "name": "vid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful vread operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "serviceCategory": {
                          "type": "array",
                          "items": {
                            "description": "A broad categorization of the service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "serviceType": {
                          "type": "array",
                          "items": {
                            "description": "The specific service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "specialty": {
                          "type": "array",
                          "items": {
                            "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "appointmentType": {
                          "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "reasonReference": {
                          "type": "array",
                          "items": {
                            "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "priority": {
                          "type": "integer",
                          "format": "int32",
                          "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "supportingInformation": {
                          "type": "array",
                          "items": {
                            "description": "Additional information to support the appointment provided when making the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "minutesDuration": {
                          "type": "integer",
                          "format": "int32",
                          "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "patientInstruction": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                        },
                        "basedOn": {
                          "type": "array",
                          "items": {
                            "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant"
                      ]
                    },
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              },
                              "minItems": 1
                            }
                          },
                          "required": [
                            "source",
                            "tag"
                          ]
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          },
                          "maxItems": 1,
                          "required": [
                            "system",
                            "value"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "minItems": 1
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant",
                        "meta",
                        "reasonCode"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              },
                              "minItems": 1
                            }
                          },
                          "required": [
                            "source",
                            "tag"
                          ]
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          },
                          "minItems": 1
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          },
                          "required": [
                            "value"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "serviceCategory": {
                          "type": "array",
                          "items": {
                            "description": "A broad categorization of the service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "serviceType": {
                          "type": "array",
                          "items": {
                            "description": "The specific service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "specialty": {
                          "type": "array",
                          "items": {
                            "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "appointmentType": {
                          "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "reasonReference": {
                          "type": "array",
                          "items": {
                            "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "priority": {
                          "type": "integer",
                          "format": "int32",
                          "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "supportingInformation": {
                          "type": "array",
                          "items": {
                            "description": "Additional information to support the appointment provided when making the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "minutesDuration": {
                          "type": "integer",
                          "format": "int32",
                          "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "patientInstruction": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                        },
                        "basedOn": {
                          "type": "array",
                          "items": {
                            "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant",
                        "extension"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                    }
                  ]
                },
                "examples": {
                  "Appointment-OnlineGPAppointmentExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "OnlineGPAppointmentExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F12345-A",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                        ]
                      },
                      "participant": [
                        {
                          "actor": {
                            "type": "Patient",
                            "identifier": {
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZZZ0008"
                            }
                          },
                          "status": "accepted"
                        }
                      ],
                      "identifier": [
                        {
                          "use": "official",
                          "system": "https://provider-org-name.co.nz/ns/appointment-identifier",
                          "value": "APT123456"
                        }
                      ],
                      "status": "fulfilled",
                      "created": "2025-01-01T09:30:00+13:00",
                      "start": "2025-01-01T10:00:00+13:00",
                      "end": "2025-01-01T10:17:00+13:00",
                      "reasonCode": [
                        {
                          "coding": [
                            {
                              "code": "266934004",
                              "system": "http://snomed.info/sct",
                              "display": "Transport problem (finding)"
                            }
                          ]
                        }
                      ]
                    }
                  },
                  "Appointment-DHOAppointmentClinicExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentClinicExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "in-person",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "In person"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                        }
                      ],
                      "status": "booked",
                      "description": "DH Fracture Consultant",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "Bring all medications you are currently taking on your admission to hospital.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "ATND",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "attender"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        },
                        {
                          "resourceType": "Slot",
                          "id": "AppointmentSlot",
                          "status": "busy",
                          "start": "2025-09-03T02:30:35Z",
                          "end": "2025-09-03T03:30:35Z",
                          "schedule": {
                            "reference": "#ClinicSchedule"
                          }
                        },
                        {
                          "resourceType": "Schedule",
                          "id": "ClinicSchedule",
                          "identifier": [
                            {
                              "value": "SOFRACONDHZ01"
                            }
                          ],
                          "active": true,
                          "actor": [
                            {
                              "identifier": {
                                "use": "official",
                                "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                                "value": "99ZZZX"
                              },
                              "display": "Dr Dotty McStuffins"
                            }
                          ]
                        }
                      ],
                      "slot": [
                        {
                          "reference": "#AppointmentSlot"
                        }
                      ],
                      "start": "2025-09-03T02:30:35Z",
                      "end": "2025-09-03T03:30:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentTelehealthExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentTelehealthExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "telehealth",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "Telehealth"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
                        }
                      ],
                      "status": "booked",
                      "description": "Telehealth follow-up",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "Please be available at the scheduled time; ensure your device is charged and you have a stable connection.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-10T02:30:35Z",
                      "end": "2025-09-10T03:00:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentTelephoneExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentTelephoneExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "telephone",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "Telephone"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#bbbbbbbb-cccc-dddd-eeee-ffffffffffff"
                        }
                      ],
                      "status": "booked",
                      "description": "Telephone follow-up",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "We will call you at the scheduled time. Please keep your phone nearby and ensure voicemail is enabled.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-17T02:30:35Z",
                      "end": "2025-09-17T02:50:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentUnstructuredExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentUnstructuredExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "in-person",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "In person"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                        }
                      ],
                      "status": "booked",
                      "description": "Physiotherapy Appointment",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "A01",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Allied Health and other"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "A01B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "A01B - Physiotherapy"
                            }
                          ]
                        }
                      ],
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-03T02:30:35Z",
                      "end": "2025-09-03T03:30:35Z"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful vread operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful vread operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful vread operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful vread operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/Appointment.r"
            ]
          }
        ]
      }
    },
    "/Appointment": {
      "get": {
        "summary": "Search for Appointment",
        "description": "Search for Appointment",
        "tags": [
          "Appointment"
        ],
        "operationId": "searchAppointment",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "name": "_id",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "identifier",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "actor",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "appointment-type",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "date",
            "in": "query",
            "style": "form",
            "explode": true,
            "required": false,
            "schema": {
              "type": "string"
            },
            "examples": {
              "date": {
                "value": "2024-12-02"
              }
            }
          },
          {
            "name": "location",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "part-status",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "patient",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "practitioner",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "status",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "appointment-method",
            "required": false,
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful search operation",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "Bundle"
                      ],
                      "description": "Resource type must be a Bundle."
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "searchset"
                      ],
                      "description": "The type of response (e.g., transaction-response or batch-response)."
                    },
                    "entry": {
                      "type": "array",
                      "description": "Entries in the bundle representing resources involved in the interaction.",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resource": {
                            "type": "object",
                            "description": "A resource in the bundle.",
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "resourceType": {
                                    "type": "string",
                                    "enum": [
                                      "Appointment"
                                    ]
                                  },
                                  "id": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                                  },
                                  "meta": {
                                    "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                    "type": "object",
                                    "properties": {
                                      "versionId": {
                                        "type": "string",
                                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                        "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                      },
                                      "lastUpdated": {
                                        "type": "string",
                                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                        "description": "When the resource last changed &ndash; e.g. when the version changed."
                                      },
                                      "source": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                      },
                                      "profile": {
                                        "type": "array",
                                        "items": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                        }
                                      },
                                      "security": {
                                        "type": "array",
                                        "items": {
                                          "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "tag": {
                                        "type": "array",
                                        "items": {
                                          "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      }
                                    }
                                  },
                                  "implicitRules": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                                  },
                                  "language": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "The base language in which the resource is written."
                                  },
                                  "text": {
                                    "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                                    "type": "object",
                                    "properties": {
                                      "status": {
                                        "type": "string",
                                        "enum": [
                                          "generated",
                                          "extensions",
                                          "additional",
                                          "empty"
                                        ],
                                        "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                                      },
                                      "div": {
                                        "type": "string",
                                        "description": "The actual narrative content, a stripped down version of XHTML."
                                      }
                                    },
                                    "required": [
                                      "status",
                                      "div"
                                    ]
                                  },
                                  "contained": {
                                    "type": "array",
                                    "items": {
                                      "type": "object",
                                      "properties": {
                                        "resourceType": {
                                          "type": "string",
                                          "enum": [
                                            "Account",
                                            "ActivityDefinition",
                                            "AdverseEvent",
                                            "AllergyIntolerance",
                                            "Appointment",
                                            "AppointmentResponse",
                                            "AuditEvent",
                                            "Basic",
                                            "Binary",
                                            "BiologicallyDerivedProduct",
                                            "BodyStructure",
                                            "Bundle",
                                            "CapabilityStatement",
                                            "CarePlan",
                                            "CareTeam",
                                            "CatalogEntry",
                                            "ChargeItem",
                                            "ChargeItemDefinition",
                                            "Claim",
                                            "ClaimResponse",
                                            "ClinicalImpression",
                                            "CodeSystem",
                                            "Communication",
                                            "CommunicationRequest",
                                            "CompartmentDefinition",
                                            "Composition",
                                            "ConceptMap",
                                            "Condition",
                                            "Consent",
                                            "Contract",
                                            "Coverage",
                                            "CoverageEligibilityRequest",
                                            "CoverageEligibilityResponse",
                                            "DetectedIssue",
                                            "Device",
                                            "DeviceDefinition",
                                            "DeviceMetric",
                                            "DeviceRequest",
                                            "DeviceUseStatement",
                                            "DiagnosticReport",
                                            "DocumentManifest",
                                            "DocumentReference",
                                            "DomainResource",
                                            "EffectEvidenceSynthesis",
                                            "Encounter",
                                            "Endpoint",
                                            "EnrollmentRequest",
                                            "EnrollmentResponse",
                                            "EpisodeOfCare",
                                            "EventDefinition",
                                            "Evidence",
                                            "EvidenceVariable",
                                            "ExampleScenario",
                                            "ExplanationOfBenefit",
                                            "FamilyMemberHistory",
                                            "Flag",
                                            "Goal",
                                            "GraphDefinition",
                                            "Group",
                                            "GuidanceResponse",
                                            "HealthcareService",
                                            "ImagingStudy",
                                            "Immunization",
                                            "ImmunizationEvaluation",
                                            "ImmunizationRecommendation",
                                            "ImplementationGuide",
                                            "InsurancePlan",
                                            "Invoice",
                                            "Library",
                                            "Linkage",
                                            "List",
                                            "Location",
                                            "Measure",
                                            "MeasureReport",
                                            "Media",
                                            "Medication",
                                            "MedicationAdministration",
                                            "MedicationDispense",
                                            "MedicationKnowledge",
                                            "MedicationRequest",
                                            "MedicationStatement",
                                            "MedicinalProduct",
                                            "MedicinalProductAuthorization",
                                            "MedicinalProductContraindication",
                                            "MedicinalProductIndication",
                                            "MedicinalProductIngredient",
                                            "MedicinalProductInteraction",
                                            "MedicinalProductManufactured",
                                            "MedicinalProductPackaged",
                                            "MedicinalProductPharmaceutical",
                                            "MedicinalProductUndesirableEffect",
                                            "MessageDefinition",
                                            "MessageHeader",
                                            "MolecularSequence",
                                            "NamingSystem",
                                            "NutritionOrder",
                                            "Observation",
                                            "ObservationDefinition",
                                            "OperationDefinition",
                                            "OperationOutcome",
                                            "Organization",
                                            "OrganizationAffiliation",
                                            "Parameters",
                                            "Patient",
                                            "PaymentNotice",
                                            "PaymentReconciliation",
                                            "Person",
                                            "PlanDefinition",
                                            "Practitioner",
                                            "PractitionerRole",
                                            "Procedure",
                                            "Provenance",
                                            "Questionnaire",
                                            "QuestionnaireResponse",
                                            "RelatedPerson",
                                            "RequestGroup",
                                            "ResearchDefinition",
                                            "ResearchElementDefinition",
                                            "ResearchStudy",
                                            "ResearchSubject",
                                            "Resource",
                                            "RiskAssessment",
                                            "RiskEvidenceSynthesis",
                                            "Schedule",
                                            "SearchParameter",
                                            "ServiceRequest",
                                            "Slot",
                                            "Specimen",
                                            "SpecimenDefinition",
                                            "StructureDefinition",
                                            "StructureMap",
                                            "Subscription",
                                            "Substance",
                                            "SubstanceNucleicAcid",
                                            "SubstancePolymer",
                                            "SubstanceProtein",
                                            "SubstanceReferenceInformation",
                                            "SubstanceSourceMaterial",
                                            "SubstanceSpecification",
                                            "SupplyDelivery",
                                            "SupplyRequest",
                                            "Task",
                                            "TerminologyCapabilities",
                                            "TestReport",
                                            "TestScript",
                                            "ValueSet",
                                            "VerificationResult",
                                            "VisionPrescription"
                                          ]
                                        },
                                        "id": {
                                          "type": "string",
                                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                                        },
                                        "meta": {
                                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                          "type": "object",
                                          "properties": {
                                            "versionId": {
                                              "type": "string",
                                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                            },
                                            "lastUpdated": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                                            },
                                            "source": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                            },
                                            "profile": {
                                              "type": "array",
                                              "items": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                              }
                                            },
                                            "security": {
                                              "type": "array",
                                              "items": {
                                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                                "type": "object",
                                                "properties": {
                                                  "system": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                  },
                                                  "version": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                  },
                                                  "code": {
                                                    "type": "string",
                                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                  },
                                                  "userSelected": {
                                                    "type": "boolean",
                                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                  }
                                                }
                                              }
                                            },
                                            "tag": {
                                              "type": "array",
                                              "items": {
                                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                                "type": "object",
                                                "properties": {
                                                  "system": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                  },
                                                  "version": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                  },
                                                  "code": {
                                                    "type": "string",
                                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                  },
                                                  "userSelected": {
                                                    "type": "boolean",
                                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                  }
                                                }
                                              }
                                            }
                                          }
                                        },
                                        "implicitRules": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                                        },
                                        "language": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "The base language in which the resource is written."
                                        }
                                      },
                                      "required": [
                                        "resourceType"
                                      ],
                                      "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                                    }
                                  },
                                  "extension": {
                                    "type": "array",
                                    "items": {
                                      "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                                      "type": "object",
                                      "additionalProperties": true
                                    }
                                  },
                                  "modifierExtension": {
                                    "type": "array",
                                    "items": {
                                      "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                      "type": "object",
                                      "additionalProperties": true
                                    }
                                  },
                                  "identifier": {
                                    "type": "array",
                                    "items": {
                                      "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                                      "type": "object",
                                      "properties": {
                                        "use": {
                                          "type": "string",
                                          "enum": [
                                            "usual",
                                            "official",
                                            "temp",
                                            "secondary",
                                            "old"
                                          ],
                                          "description": "The purpose of this identifier."
                                        },
                                        "type": {
                                          "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                          "type": "object",
                                          "properties": {
                                            "coding": {
                                              "type": "array",
                                              "items": {
                                                "description": "A reference to a code defined by a terminology system.",
                                                "type": "object",
                                                "properties": {
                                                  "system": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                  },
                                                  "version": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                  },
                                                  "code": {
                                                    "type": "string",
                                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                  },
                                                  "userSelected": {
                                                    "type": "boolean",
                                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                  }
                                                }
                                              }
                                            },
                                            "text": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                            }
                                          }
                                        },
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                                        },
                                        "value": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                                        },
                                        "period": {
                                          "description": "Time period during which identifier is/was valid for use.",
                                          "type": "object",
                                          "properties": {
                                            "start": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The start of the period. The boundary is inclusive."
                                            },
                                            "end": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                            }
                                          }
                                        },
                                        "assigner": {
                                          "description": "Organization that issued/manages the identifier.",
                                          "type": "object",
                                          "properties": {
                                            "reference": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                            },
                                            "type": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                            },
                                            "identifier": {
                                              "type": "object",
                                              "additionalProperties": true,
                                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                            }
                                          }
                                        }
                                      }
                                    }
                                  },
                                  "status": {
                                    "type": "string",
                                    "enum": [
                                      "proposed",
                                      "pending",
                                      "booked",
                                      "arrived",
                                      "fulfilled",
                                      "cancelled",
                                      "noshow",
                                      "entered-in-error",
                                      "checked-in",
                                      "waitlist"
                                    ],
                                    "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                                  },
                                  "cancelationReason": {
                                    "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                                    "type": "object",
                                    "properties": {
                                      "coding": {
                                        "type": "array",
                                        "items": {
                                          "description": "A reference to a code defined by a terminology system.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "text": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                      }
                                    }
                                  },
                                  "serviceCategory": {
                                    "type": "array",
                                    "items": {
                                      "description": "A broad categorization of the service that is to be performed during this appointment.",
                                      "type": "object",
                                      "properties": {
                                        "coding": {
                                          "type": "array",
                                          "items": {
                                            "description": "A reference to a code defined by a terminology system.",
                                            "type": "object",
                                            "properties": {
                                              "system": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                              },
                                              "version": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                              },
                                              "code": {
                                                "type": "string",
                                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                              },
                                              "display": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                              },
                                              "userSelected": {
                                                "type": "boolean",
                                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                              }
                                            }
                                          }
                                        },
                                        "text": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                        }
                                      }
                                    }
                                  },
                                  "serviceType": {
                                    "type": "array",
                                    "items": {
                                      "description": "The specific service that is to be performed during this appointment.",
                                      "type": "object",
                                      "properties": {
                                        "coding": {
                                          "type": "array",
                                          "items": {
                                            "description": "A reference to a code defined by a terminology system.",
                                            "type": "object",
                                            "properties": {
                                              "system": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                              },
                                              "version": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                              },
                                              "code": {
                                                "type": "string",
                                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                              },
                                              "display": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                              },
                                              "userSelected": {
                                                "type": "boolean",
                                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                              }
                                            }
                                          }
                                        },
                                        "text": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                        }
                                      }
                                    }
                                  },
                                  "specialty": {
                                    "type": "array",
                                    "items": {
                                      "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                                      "type": "object",
                                      "properties": {
                                        "coding": {
                                          "type": "array",
                                          "items": {
                                            "description": "A reference to a code defined by a terminology system.",
                                            "type": "object",
                                            "properties": {
                                              "system": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                              },
                                              "version": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                              },
                                              "code": {
                                                "type": "string",
                                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                              },
                                              "display": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                              },
                                              "userSelected": {
                                                "type": "boolean",
                                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                              }
                                            }
                                          }
                                        },
                                        "text": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                        }
                                      }
                                    }
                                  },
                                  "appointmentType": {
                                    "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                                    "type": "object",
                                    "properties": {
                                      "coding": {
                                        "type": "array",
                                        "items": {
                                          "description": "A reference to a code defined by a terminology system.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "text": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                      }
                                    }
                                  },
                                  "reasonCode": {
                                    "type": "array",
                                    "items": {
                                      "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                                      "type": "object",
                                      "properties": {
                                        "coding": {
                                          "type": "array",
                                          "items": {
                                            "description": "A reference to a code defined by a terminology system.",
                                            "type": "object",
                                            "properties": {
                                              "system": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                              },
                                              "version": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                              },
                                              "code": {
                                                "type": "string",
                                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                              },
                                              "display": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                              },
                                              "userSelected": {
                                                "type": "boolean",
                                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                              }
                                            }
                                          }
                                        },
                                        "text": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                        }
                                      }
                                    }
                                  },
                                  "reasonReference": {
                                    "type": "array",
                                    "items": {
                                      "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    }
                                  },
                                  "priority": {
                                    "type": "integer",
                                    "format": "int32",
                                    "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                                  },
                                  "description": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                                  },
                                  "supportingInformation": {
                                    "type": "array",
                                    "items": {
                                      "description": "Additional information to support the appointment provided when making the appointment.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    }
                                  },
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "Date/Time that the appointment is to take place."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "Date/Time that the appointment is to conclude."
                                  },
                                  "minutesDuration": {
                                    "type": "integer",
                                    "format": "int32",
                                    "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                                  },
                                  "slot": {
                                    "type": "array",
                                    "items": {
                                      "description": "The slots from the participants' schedules that will be filled by the appointment.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    }
                                  },
                                  "created": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                                  },
                                  "comment": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Additional comments about the appointment."
                                  },
                                  "patientInstruction": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                                  },
                                  "basedOn": {
                                    "type": "array",
                                    "items": {
                                      "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    }
                                  },
                                  "participant": {
                                    "type": "array",
                                    "items": {
                                      "description": "List of participants involved in the appointment.",
                                      "type": "object",
                                      "properties": {
                                        "modifierExtension": {
                                          "type": "array",
                                          "items": {
                                            "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                            "type": "object",
                                            "additionalProperties": true
                                          }
                                        },
                                        "type": {
                                          "type": "array",
                                          "items": {
                                            "description": "Role of participant in the appointment.",
                                            "type": "object",
                                            "properties": {
                                              "coding": {
                                                "type": "array",
                                                "items": {
                                                  "description": "A reference to a code defined by a terminology system.",
                                                  "type": "object",
                                                  "properties": {
                                                    "system": {
                                                      "type": "string",
                                                      "pattern": "\\S*",
                                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                    },
                                                    "version": {
                                                      "type": "string",
                                                      "pattern": "[ \\r\\n\\t\\S]+",
                                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                    },
                                                    "code": {
                                                      "type": "string",
                                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                    },
                                                    "display": {
                                                      "type": "string",
                                                      "pattern": "[ \\r\\n\\t\\S]+",
                                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                    },
                                                    "userSelected": {
                                                      "type": "boolean",
                                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                    }
                                                  }
                                                }
                                              },
                                              "text": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                              }
                                            }
                                          }
                                        },
                                        "actor": {
                                          "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                          "type": "object",
                                          "properties": {
                                            "reference": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                            },
                                            "type": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                            },
                                            "identifier": {
                                              "type": "object",
                                              "additionalProperties": true,
                                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                            }
                                          }
                                        },
                                        "required": {
                                          "type": "string",
                                          "enum": [
                                            "required",
                                            "optional",
                                            "information-only"
                                          ],
                                          "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                                        },
                                        "status": {
                                          "type": "string",
                                          "enum": [
                                            "accepted",
                                            "declined",
                                            "tentative",
                                            "needs-action"
                                          ],
                                          "description": "Participation status of the actor."
                                        },
                                        "period": {
                                          "description": "Participation period of the actor.",
                                          "type": "object",
                                          "properties": {
                                            "start": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The start of the period. The boundary is inclusive."
                                            },
                                            "end": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                            }
                                          }
                                        }
                                      },
                                      "required": [
                                        "status"
                                      ]
                                    },
                                    "minItems": 1
                                  },
                                  "requestedPeriod": {
                                    "type": "array",
                                    "items": {
                                      "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                                      "type": "object",
                                      "properties": {
                                        "start": {
                                          "type": "string",
                                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                          "description": "The start of the period. The boundary is inclusive."
                                        },
                                        "end": {
                                          "type": "string",
                                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                          "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                        }
                                      }
                                    }
                                  }
                                },
                                "required": [
                                  "resourceType",
                                  "status",
                                  "participant"
                                ]
                              },
                              {
                                "type": "object",
                                "properties": {
                                  "resourceType": {
                                    "type": "string",
                                    "enum": [
                                      "Appointment"
                                    ]
                                  },
                                  "id": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                                  },
                                  "meta": {
                                    "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                    "type": "object",
                                    "properties": {
                                      "versionId": {
                                        "type": "string",
                                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                        "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                      },
                                      "lastUpdated": {
                                        "type": "string",
                                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                        "description": "When the resource last changed &ndash; e.g. when the version changed."
                                      },
                                      "source": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                      },
                                      "profile": {
                                        "type": "array",
                                        "items": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                        }
                                      },
                                      "security": {
                                        "type": "array",
                                        "items": {
                                          "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "tag": {
                                        "type": "array",
                                        "items": {
                                          "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        },
                                        "minItems": 1
                                      }
                                    },
                                    "required": [
                                      "source",
                                      "tag"
                                    ]
                                  },
                                  "implicitRules": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                                  },
                                  "language": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "The base language in which the resource is written."
                                  },
                                  "text": {
                                    "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                                    "type": "object",
                                    "properties": {
                                      "status": {
                                        "type": "string",
                                        "enum": [
                                          "generated",
                                          "extensions",
                                          "additional",
                                          "empty"
                                        ],
                                        "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                                      },
                                      "div": {
                                        "type": "string",
                                        "description": "The actual narrative content, a stripped down version of XHTML."
                                      }
                                    },
                                    "required": [
                                      "status",
                                      "div"
                                    ]
                                  },
                                  "extension": {
                                    "type": "array",
                                    "items": {
                                      "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                                      "type": "object",
                                      "additionalProperties": true
                                    }
                                  },
                                  "modifierExtension": {
                                    "type": "array",
                                    "items": {
                                      "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                      "type": "object",
                                      "additionalProperties": true
                                    }
                                  },
                                  "identifier": {
                                    "type": "array",
                                    "items": {
                                      "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                                      "type": "object",
                                      "properties": {
                                        "use": {
                                          "type": "string",
                                          "enum": [
                                            "usual",
                                            "official",
                                            "temp",
                                            "secondary",
                                            "old"
                                          ],
                                          "description": "The purpose of this identifier."
                                        },
                                        "type": {
                                          "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                          "type": "object",
                                          "properties": {
                                            "coding": {
                                              "type": "array",
                                              "items": {
                                                "description": "A reference to a code defined by a terminology system.",
                                                "type": "object",
                                                "properties": {
                                                  "system": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                  },
                                                  "version": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                  },
                                                  "code": {
                                                    "type": "string",
                                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                  },
                                                  "userSelected": {
                                                    "type": "boolean",
                                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                  }
                                                }
                                              }
                                            },
                                            "text": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                            }
                                          }
                                        },
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                                        },
                                        "value": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                                        },
                                        "period": {
                                          "description": "Time period during which identifier is/was valid for use.",
                                          "type": "object",
                                          "properties": {
                                            "start": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The start of the period. The boundary is inclusive."
                                            },
                                            "end": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                            }
                                          }
                                        },
                                        "assigner": {
                                          "description": "Organization that issued/manages the identifier.",
                                          "type": "object",
                                          "properties": {
                                            "reference": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                            },
                                            "type": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                            },
                                            "identifier": {
                                              "type": "object",
                                              "additionalProperties": true,
                                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                            }
                                          }
                                        }
                                      }
                                    },
                                    "maxItems": 1,
                                    "required": [
                                      "system",
                                      "value"
                                    ]
                                  },
                                  "status": {
                                    "type": "string",
                                    "enum": [
                                      "proposed",
                                      "pending",
                                      "booked",
                                      "arrived",
                                      "fulfilled",
                                      "cancelled",
                                      "noshow",
                                      "entered-in-error",
                                      "checked-in",
                                      "waitlist"
                                    ],
                                    "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                                  },
                                  "cancelationReason": {
                                    "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                                    "type": "object",
                                    "properties": {
                                      "coding": {
                                        "type": "array",
                                        "items": {
                                          "description": "A reference to a code defined by a terminology system.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "text": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                      }
                                    }
                                  },
                                  "reasonCode": {
                                    "type": "array",
                                    "items": {
                                      "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                                      "type": "object",
                                      "properties": {
                                        "coding": {
                                          "type": "array",
                                          "items": {
                                            "description": "A reference to a code defined by a terminology system.",
                                            "type": "object",
                                            "properties": {
                                              "system": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                              },
                                              "version": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                              },
                                              "code": {
                                                "type": "string",
                                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                              },
                                              "display": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                              },
                                              "userSelected": {
                                                "type": "boolean",
                                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                              }
                                            }
                                          }
                                        },
                                        "text": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                        }
                                      }
                                    },
                                    "minItems": 1
                                  },
                                  "description": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                                  },
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "Date/Time that the appointment is to take place."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "Date/Time that the appointment is to conclude."
                                  },
                                  "slot": {
                                    "type": "array",
                                    "items": {
                                      "description": "The slots from the participants' schedules that will be filled by the appointment.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    }
                                  },
                                  "created": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                                  },
                                  "comment": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Additional comments about the appointment."
                                  },
                                  "participant": {
                                    "type": "array",
                                    "items": {
                                      "description": "List of participants involved in the appointment.",
                                      "type": "object",
                                      "properties": {
                                        "modifierExtension": {
                                          "type": "array",
                                          "items": {
                                            "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                            "type": "object",
                                            "additionalProperties": true
                                          }
                                        },
                                        "type": {
                                          "type": "array",
                                          "items": {
                                            "description": "Role of participant in the appointment.",
                                            "type": "object",
                                            "properties": {
                                              "coding": {
                                                "type": "array",
                                                "items": {
                                                  "description": "A reference to a code defined by a terminology system.",
                                                  "type": "object",
                                                  "properties": {
                                                    "system": {
                                                      "type": "string",
                                                      "pattern": "\\S*",
                                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                    },
                                                    "version": {
                                                      "type": "string",
                                                      "pattern": "[ \\r\\n\\t\\S]+",
                                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                    },
                                                    "code": {
                                                      "type": "string",
                                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                    },
                                                    "display": {
                                                      "type": "string",
                                                      "pattern": "[ \\r\\n\\t\\S]+",
                                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                    },
                                                    "userSelected": {
                                                      "type": "boolean",
                                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                    }
                                                  }
                                                }
                                              },
                                              "text": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                              }
                                            }
                                          }
                                        },
                                        "actor": {
                                          "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                          "type": "object",
                                          "properties": {
                                            "reference": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                            },
                                            "type": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                            },
                                            "identifier": {
                                              "type": "object",
                                              "additionalProperties": true,
                                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                            }
                                          }
                                        },
                                        "required": {
                                          "type": "string",
                                          "enum": [
                                            "required",
                                            "optional",
                                            "information-only"
                                          ],
                                          "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                                        },
                                        "status": {
                                          "type": "string",
                                          "enum": [
                                            "accepted",
                                            "declined",
                                            "tentative",
                                            "needs-action"
                                          ],
                                          "description": "Participation status of the actor."
                                        },
                                        "period": {
                                          "description": "Participation period of the actor.",
                                          "type": "object",
                                          "properties": {
                                            "start": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The start of the period. The boundary is inclusive."
                                            },
                                            "end": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                            }
                                          }
                                        }
                                      },
                                      "required": [
                                        "status"
                                      ]
                                    },
                                    "minItems": 1
                                  },
                                  "requestedPeriod": {
                                    "type": "array",
                                    "items": {
                                      "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                                      "type": "object",
                                      "properties": {
                                        "start": {
                                          "type": "string",
                                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                          "description": "The start of the period. The boundary is inclusive."
                                        },
                                        "end": {
                                          "type": "string",
                                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                          "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                        }
                                      }
                                    }
                                  }
                                },
                                "required": [
                                  "resourceType",
                                  "status",
                                  "participant",
                                  "meta",
                                  "reasonCode"
                                ],
                                "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                              },
                              {
                                "type": "object",
                                "properties": {
                                  "resourceType": {
                                    "type": "string",
                                    "enum": [
                                      "Appointment"
                                    ]
                                  },
                                  "id": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                                  },
                                  "meta": {
                                    "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                    "type": "object",
                                    "properties": {
                                      "versionId": {
                                        "type": "string",
                                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                        "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                      },
                                      "lastUpdated": {
                                        "type": "string",
                                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                        "description": "When the resource last changed &ndash; e.g. when the version changed."
                                      },
                                      "source": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                      },
                                      "profile": {
                                        "type": "array",
                                        "items": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                        }
                                      },
                                      "security": {
                                        "type": "array",
                                        "items": {
                                          "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "tag": {
                                        "type": "array",
                                        "items": {
                                          "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        },
                                        "minItems": 1
                                      }
                                    },
                                    "required": [
                                      "source",
                                      "tag"
                                    ]
                                  },
                                  "implicitRules": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                                  },
                                  "language": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "The base language in which the resource is written."
                                  },
                                  "text": {
                                    "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                                    "type": "object",
                                    "properties": {
                                      "status": {
                                        "type": "string",
                                        "enum": [
                                          "generated",
                                          "extensions",
                                          "additional",
                                          "empty"
                                        ],
                                        "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                                      },
                                      "div": {
                                        "type": "string",
                                        "description": "The actual narrative content, a stripped down version of XHTML."
                                      }
                                    },
                                    "required": [
                                      "status",
                                      "div"
                                    ]
                                  },
                                  "contained": {
                                    "type": "array",
                                    "items": {
                                      "type": "object",
                                      "properties": {
                                        "resourceType": {
                                          "type": "string",
                                          "enum": [
                                            "Account",
                                            "ActivityDefinition",
                                            "AdverseEvent",
                                            "AllergyIntolerance",
                                            "Appointment",
                                            "AppointmentResponse",
                                            "AuditEvent",
                                            "Basic",
                                            "Binary",
                                            "BiologicallyDerivedProduct",
                                            "BodyStructure",
                                            "Bundle",
                                            "CapabilityStatement",
                                            "CarePlan",
                                            "CareTeam",
                                            "CatalogEntry",
                                            "ChargeItem",
                                            "ChargeItemDefinition",
                                            "Claim",
                                            "ClaimResponse",
                                            "ClinicalImpression",
                                            "CodeSystem",
                                            "Communication",
                                            "CommunicationRequest",
                                            "CompartmentDefinition",
                                            "Composition",
                                            "ConceptMap",
                                            "Condition",
                                            "Consent",
                                            "Contract",
                                            "Coverage",
                                            "CoverageEligibilityRequest",
                                            "CoverageEligibilityResponse",
                                            "DetectedIssue",
                                            "Device",
                                            "DeviceDefinition",
                                            "DeviceMetric",
                                            "DeviceRequest",
                                            "DeviceUseStatement",
                                            "DiagnosticReport",
                                            "DocumentManifest",
                                            "DocumentReference",
                                            "DomainResource",
                                            "EffectEvidenceSynthesis",
                                            "Encounter",
                                            "Endpoint",
                                            "EnrollmentRequest",
                                            "EnrollmentResponse",
                                            "EpisodeOfCare",
                                            "EventDefinition",
                                            "Evidence",
                                            "EvidenceVariable",
                                            "ExampleScenario",
                                            "ExplanationOfBenefit",
                                            "FamilyMemberHistory",
                                            "Flag",
                                            "Goal",
                                            "GraphDefinition",
                                            "Group",
                                            "GuidanceResponse",
                                            "HealthcareService",
                                            "ImagingStudy",
                                            "Immunization",
                                            "ImmunizationEvaluation",
                                            "ImmunizationRecommendation",
                                            "ImplementationGuide",
                                            "InsurancePlan",
                                            "Invoice",
                                            "Library",
                                            "Linkage",
                                            "List",
                                            "Location",
                                            "Measure",
                                            "MeasureReport",
                                            "Media",
                                            "Medication",
                                            "MedicationAdministration",
                                            "MedicationDispense",
                                            "MedicationKnowledge",
                                            "MedicationRequest",
                                            "MedicationStatement",
                                            "MedicinalProduct",
                                            "MedicinalProductAuthorization",
                                            "MedicinalProductContraindication",
                                            "MedicinalProductIndication",
                                            "MedicinalProductIngredient",
                                            "MedicinalProductInteraction",
                                            "MedicinalProductManufactured",
                                            "MedicinalProductPackaged",
                                            "MedicinalProductPharmaceutical",
                                            "MedicinalProductUndesirableEffect",
                                            "MessageDefinition",
                                            "MessageHeader",
                                            "MolecularSequence",
                                            "NamingSystem",
                                            "NutritionOrder",
                                            "Observation",
                                            "ObservationDefinition",
                                            "OperationDefinition",
                                            "OperationOutcome",
                                            "Organization",
                                            "OrganizationAffiliation",
                                            "Parameters",
                                            "Patient",
                                            "PaymentNotice",
                                            "PaymentReconciliation",
                                            "Person",
                                            "PlanDefinition",
                                            "Practitioner",
                                            "PractitionerRole",
                                            "Procedure",
                                            "Provenance",
                                            "Questionnaire",
                                            "QuestionnaireResponse",
                                            "RelatedPerson",
                                            "RequestGroup",
                                            "ResearchDefinition",
                                            "ResearchElementDefinition",
                                            "ResearchStudy",
                                            "ResearchSubject",
                                            "Resource",
                                            "RiskAssessment",
                                            "RiskEvidenceSynthesis",
                                            "Schedule",
                                            "SearchParameter",
                                            "ServiceRequest",
                                            "Slot",
                                            "Specimen",
                                            "SpecimenDefinition",
                                            "StructureDefinition",
                                            "StructureMap",
                                            "Subscription",
                                            "Substance",
                                            "SubstanceNucleicAcid",
                                            "SubstancePolymer",
                                            "SubstanceProtein",
                                            "SubstanceReferenceInformation",
                                            "SubstanceSourceMaterial",
                                            "SubstanceSpecification",
                                            "SupplyDelivery",
                                            "SupplyRequest",
                                            "Task",
                                            "TerminologyCapabilities",
                                            "TestReport",
                                            "TestScript",
                                            "ValueSet",
                                            "VerificationResult",
                                            "VisionPrescription"
                                          ]
                                        },
                                        "id": {
                                          "type": "string",
                                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                                        },
                                        "meta": {
                                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                          "type": "object",
                                          "properties": {
                                            "versionId": {
                                              "type": "string",
                                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                            },
                                            "lastUpdated": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                                            },
                                            "source": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                            },
                                            "profile": {
                                              "type": "array",
                                              "items": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                              }
                                            },
                                            "security": {
                                              "type": "array",
                                              "items": {
                                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                                "type": "object",
                                                "properties": {
                                                  "system": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                  },
                                                  "version": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                  },
                                                  "code": {
                                                    "type": "string",
                                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                  },
                                                  "userSelected": {
                                                    "type": "boolean",
                                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                  }
                                                }
                                              }
                                            },
                                            "tag": {
                                              "type": "array",
                                              "items": {
                                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                                "type": "object",
                                                "properties": {
                                                  "system": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                  },
                                                  "version": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                  },
                                                  "code": {
                                                    "type": "string",
                                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                  },
                                                  "userSelected": {
                                                    "type": "boolean",
                                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                  }
                                                }
                                              }
                                            }
                                          }
                                        },
                                        "implicitRules": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                                        },
                                        "language": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "The base language in which the resource is written."
                                        }
                                      },
                                      "required": [
                                        "resourceType"
                                      ],
                                      "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                                    }
                                  },
                                  "extension": {
                                    "type": "array",
                                    "items": {
                                      "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                                      "type": "object",
                                      "additionalProperties": true
                                    },
                                    "minItems": 1
                                  },
                                  "modifierExtension": {
                                    "type": "array",
                                    "items": {
                                      "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                      "type": "object",
                                      "additionalProperties": true
                                    }
                                  },
                                  "identifier": {
                                    "type": "array",
                                    "items": {
                                      "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                                      "type": "object",
                                      "properties": {
                                        "use": {
                                          "type": "string",
                                          "enum": [
                                            "usual",
                                            "official",
                                            "temp",
                                            "secondary",
                                            "old"
                                          ],
                                          "description": "The purpose of this identifier."
                                        },
                                        "type": {
                                          "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                          "type": "object",
                                          "properties": {
                                            "coding": {
                                              "type": "array",
                                              "items": {
                                                "description": "A reference to a code defined by a terminology system.",
                                                "type": "object",
                                                "properties": {
                                                  "system": {
                                                    "type": "string",
                                                    "pattern": "\\S*",
                                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                  },
                                                  "version": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                  },
                                                  "code": {
                                                    "type": "string",
                                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                  },
                                                  "display": {
                                                    "type": "string",
                                                    "pattern": "[ \\r\\n\\t\\S]+",
                                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                  },
                                                  "userSelected": {
                                                    "type": "boolean",
                                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                  }
                                                }
                                              }
                                            },
                                            "text": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                            }
                                          }
                                        },
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                                        },
                                        "value": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                                        },
                                        "period": {
                                          "description": "Time period during which identifier is/was valid for use.",
                                          "type": "object",
                                          "properties": {
                                            "start": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The start of the period. The boundary is inclusive."
                                            },
                                            "end": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                            }
                                          }
                                        },
                                        "assigner": {
                                          "description": "Organization that issued/manages the identifier.",
                                          "type": "object",
                                          "properties": {
                                            "reference": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                            },
                                            "type": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                            },
                                            "identifier": {
                                              "type": "object",
                                              "additionalProperties": true,
                                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                            }
                                          }
                                        }
                                      }
                                    },
                                    "required": [
                                      "value"
                                    ]
                                  },
                                  "status": {
                                    "type": "string",
                                    "enum": [
                                      "proposed",
                                      "pending",
                                      "booked",
                                      "arrived",
                                      "fulfilled",
                                      "cancelled",
                                      "noshow",
                                      "entered-in-error",
                                      "checked-in",
                                      "waitlist"
                                    ],
                                    "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                                  },
                                  "cancelationReason": {
                                    "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                                    "type": "object",
                                    "properties": {
                                      "coding": {
                                        "type": "array",
                                        "items": {
                                          "description": "A reference to a code defined by a terminology system.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "text": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                      }
                                    }
                                  },
                                  "serviceCategory": {
                                    "type": "array",
                                    "items": {
                                      "description": "A broad categorization of the service that is to be performed during this appointment.",
                                      "type": "object",
                                      "properties": {
                                        "coding": {
                                          "type": "array",
                                          "items": {
                                            "description": "A reference to a code defined by a terminology system.",
                                            "type": "object",
                                            "properties": {
                                              "system": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                              },
                                              "version": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                              },
                                              "code": {
                                                "type": "string",
                                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                              },
                                              "display": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                              },
                                              "userSelected": {
                                                "type": "boolean",
                                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                              }
                                            }
                                          }
                                        },
                                        "text": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                        }
                                      }
                                    }
                                  },
                                  "serviceType": {
                                    "type": "array",
                                    "items": {
                                      "description": "The specific service that is to be performed during this appointment.",
                                      "type": "object",
                                      "properties": {
                                        "coding": {
                                          "type": "array",
                                          "items": {
                                            "description": "A reference to a code defined by a terminology system.",
                                            "type": "object",
                                            "properties": {
                                              "system": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                              },
                                              "version": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                              },
                                              "code": {
                                                "type": "string",
                                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                              },
                                              "display": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                              },
                                              "userSelected": {
                                                "type": "boolean",
                                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                              }
                                            }
                                          }
                                        },
                                        "text": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                        }
                                      }
                                    }
                                  },
                                  "specialty": {
                                    "type": "array",
                                    "items": {
                                      "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                                      "type": "object",
                                      "properties": {
                                        "coding": {
                                          "type": "array",
                                          "items": {
                                            "description": "A reference to a code defined by a terminology system.",
                                            "type": "object",
                                            "properties": {
                                              "system": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                              },
                                              "version": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                              },
                                              "code": {
                                                "type": "string",
                                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                              },
                                              "display": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                              },
                                              "userSelected": {
                                                "type": "boolean",
                                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                              }
                                            }
                                          }
                                        },
                                        "text": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                        }
                                      }
                                    }
                                  },
                                  "appointmentType": {
                                    "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                                    "type": "object",
                                    "properties": {
                                      "coding": {
                                        "type": "array",
                                        "items": {
                                          "description": "A reference to a code defined by a terminology system.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                            },
                                            "version": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                            },
                                            "code": {
                                              "type": "string",
                                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                              "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                            },
                                            "userSelected": {
                                              "type": "boolean",
                                              "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                            }
                                          }
                                        }
                                      },
                                      "text": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                      }
                                    }
                                  },
                                  "reasonCode": {
                                    "type": "array",
                                    "items": {
                                      "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                                      "type": "object",
                                      "properties": {
                                        "coding": {
                                          "type": "array",
                                          "items": {
                                            "description": "A reference to a code defined by a terminology system.",
                                            "type": "object",
                                            "properties": {
                                              "system": {
                                                "type": "string",
                                                "pattern": "\\S*",
                                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                              },
                                              "version": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                              },
                                              "code": {
                                                "type": "string",
                                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                              },
                                              "display": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                              },
                                              "userSelected": {
                                                "type": "boolean",
                                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                              }
                                            }
                                          }
                                        },
                                        "text": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                        }
                                      }
                                    }
                                  },
                                  "reasonReference": {
                                    "type": "array",
                                    "items": {
                                      "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    }
                                  },
                                  "priority": {
                                    "type": "integer",
                                    "format": "int32",
                                    "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                                  },
                                  "description": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                                  },
                                  "supportingInformation": {
                                    "type": "array",
                                    "items": {
                                      "description": "Additional information to support the appointment provided when making the appointment.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    }
                                  },
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "Date/Time that the appointment is to take place."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "Date/Time that the appointment is to conclude."
                                  },
                                  "minutesDuration": {
                                    "type": "integer",
                                    "format": "int32",
                                    "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                                  },
                                  "slot": {
                                    "type": "array",
                                    "items": {
                                      "description": "The slots from the participants' schedules that will be filled by the appointment.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    }
                                  },
                                  "created": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                                  },
                                  "comment": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Additional comments about the appointment."
                                  },
                                  "patientInstruction": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                                  },
                                  "basedOn": {
                                    "type": "array",
                                    "items": {
                                      "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    }
                                  },
                                  "participant": {
                                    "type": "array",
                                    "items": {
                                      "description": "List of participants involved in the appointment.",
                                      "type": "object",
                                      "properties": {
                                        "modifierExtension": {
                                          "type": "array",
                                          "items": {
                                            "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                            "type": "object",
                                            "additionalProperties": true
                                          }
                                        },
                                        "type": {
                                          "type": "array",
                                          "items": {
                                            "description": "Role of participant in the appointment.",
                                            "type": "object",
                                            "properties": {
                                              "coding": {
                                                "type": "array",
                                                "items": {
                                                  "description": "A reference to a code defined by a terminology system.",
                                                  "type": "object",
                                                  "properties": {
                                                    "system": {
                                                      "type": "string",
                                                      "pattern": "\\S*",
                                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                                    },
                                                    "version": {
                                                      "type": "string",
                                                      "pattern": "[ \\r\\n\\t\\S]+",
                                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                                    },
                                                    "code": {
                                                      "type": "string",
                                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                                    },
                                                    "display": {
                                                      "type": "string",
                                                      "pattern": "[ \\r\\n\\t\\S]+",
                                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                                    },
                                                    "userSelected": {
                                                      "type": "boolean",
                                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                                    }
                                                  }
                                                }
                                              },
                                              "text": {
                                                "type": "string",
                                                "pattern": "[ \\r\\n\\t\\S]+",
                                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                              }
                                            }
                                          }
                                        },
                                        "actor": {
                                          "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                          "type": "object",
                                          "properties": {
                                            "reference": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                            },
                                            "type": {
                                              "type": "string",
                                              "pattern": "\\S*",
                                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                            },
                                            "identifier": {
                                              "type": "object",
                                              "additionalProperties": true,
                                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                            },
                                            "display": {
                                              "type": "string",
                                              "pattern": "[ \\r\\n\\t\\S]+",
                                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                            }
                                          }
                                        },
                                        "required": {
                                          "type": "string",
                                          "enum": [
                                            "required",
                                            "optional",
                                            "information-only"
                                          ],
                                          "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                                        },
                                        "status": {
                                          "type": "string",
                                          "enum": [
                                            "accepted",
                                            "declined",
                                            "tentative",
                                            "needs-action"
                                          ],
                                          "description": "Participation status of the actor."
                                        },
                                        "period": {
                                          "description": "Participation period of the actor.",
                                          "type": "object",
                                          "properties": {
                                            "start": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The start of the period. The boundary is inclusive."
                                            },
                                            "end": {
                                              "type": "string",
                                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                            }
                                          }
                                        }
                                      },
                                      "required": [
                                        "status"
                                      ]
                                    },
                                    "minItems": 1
                                  },
                                  "requestedPeriod": {
                                    "type": "array",
                                    "items": {
                                      "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                                      "type": "object",
                                      "properties": {
                                        "start": {
                                          "type": "string",
                                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                          "description": "The start of the period. The boundary is inclusive."
                                        },
                                        "end": {
                                          "type": "string",
                                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                          "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                        }
                                      }
                                    }
                                  }
                                },
                                "required": [
                                  "resourceType",
                                  "status",
                                  "participant",
                                  "extension"
                                ],
                                "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                              }
                            ]
                          },
                          "fullUrl": {
                            "type": "string",
                            "description": "The full url of the resource"
                          },
                          "search": {
                            "type": "object",
                            "properties": {
                              "mode": {
                                "type": "string",
                                "enum": [
                                  "match"
                                ],
                                "description": "The search mode."
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                },
                "examples": {
                  "searchset-example": {
                    "value": {
                      "resourceType": "Bundle",
                      "type": "searchset",
                      "entry": [
                        {
                          "fullUrl": "https://fhir.api.digital.health.nz/R4/Appointment/DHOAppointmentClinicExample",
                          "resource": {
                            "resourceType": "Appointment",
                            "id": "DHOAppointmentClinicExample",
                            "meta": {
                              "tag": [
                                {
                                  "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                                  "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                                }
                              ],
                              "lastUpdated": "2025-11-11T02:29:24.844Z",
                              "versionId": "3",
                              "profile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                              ],
                              "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                            },
                            "extension": [
                              {
                                "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                                "valueCodeableConcept": {
                                  "coding": [
                                    {
                                      "code": "in-person",
                                      "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                      "display": "In person"
                                    }
                                  ]
                                }
                              }
                            ],
                            "identifier": [
                              {
                                "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                              }
                            ],
                            "status": "booked",
                            "description": "DH Fracture Consultant",
                            "serviceCategory": [
                              {
                                "coding": [
                                  {
                                    "code": "S45",
                                    "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                                    "display": "Orthopaedic Surgery"
                                  }
                                ]
                              }
                            ],
                            "serviceType": [
                              {
                                "coding": [
                                  {
                                    "code": "S45B",
                                    "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                                    "display": "S45B - Fracture Clinic"
                                  }
                                ]
                              }
                            ],
                            "patientInstruction": "Bring all medications you are currently taking on your admission to hospital.",
                            "participant": [
                              {
                                "required": "required",
                                "status": "needs-action",
                                "actor": {
                                  "identifier": {
                                    "use": "official",
                                    "system": "https://standards.digital.health.nz/ns/nhi-id",
                                    "value": "ZXP7823"
                                  },
                                  "display": "Carey Carrington"
                                }
                              },
                              {
                                "type": [
                                  {
                                    "coding": [
                                      {
                                        "code": "ATND",
                                        "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                        "display": "attender"
                                      }
                                    ]
                                  }
                                ],
                                "required": "required",
                                "status": "accepted",
                                "actor": {
                                  "identifier": {
                                    "use": "official",
                                    "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                                    "value": "99ZZZX"
                                  },
                                  "display": "Dr Dotty McStuffins"
                                }
                              },
                              {
                                "type": [
                                  {
                                    "coding": [
                                      {
                                        "code": "CON",
                                        "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                        "display": "consultant"
                                      }
                                    ]
                                  }
                                ],
                                "required": "required",
                                "status": "accepted",
                                "actor": {
                                  "identifier": {
                                    "use": "official",
                                    "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                                    "value": "99ZZZX"
                                  },
                                  "display": "Dr Dotty McStuffins"
                                }
                              },
                              {
                                "required": "required",
                                "status": "accepted",
                                "actor": {
                                  "reference": "#DHOClinicLocation"
                                }
                              }
                            ],
                            "contained": [
                              {
                                "resourceType": "Location",
                                "id": "DHOClinicLocation",
                                "meta": {
                                  "profile": [
                                    "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                                  ]
                                },
                                "identifier": [
                                  {
                                    "value": "4211-K01"
                                  }
                                ],
                                "name": "Dunedin Hospital Outpatients, Clinic K01",
                                "partOf": {
                                  "type": "Location",
                                  "identifier": {
                                    "value": "4211",
                                    "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                                  },
                                  "display": "Dunedin Hospital"
                                },
                                "address": {
                                  "use": "work",
                                  "type": "physical",
                                  "line": [
                                    "350 Cumberland Street",
                                    "Dunedin Central"
                                  ],
                                  "city": "Dunedin",
                                  "postalCode": "9016",
                                  "country": "New Zealand"
                                }
                              },
                              {
                                "resourceType": "Slot",
                                "id": "AppointmentSlot",
                                "status": "busy",
                                "start": "2025-09-03T02:30:35Z",
                                "end": "2025-09-03T03:30:35Z",
                                "schedule": {
                                  "reference": "#ClinicSchedule"
                                }
                              },
                              {
                                "resourceType": "Schedule",
                                "id": "ClinicSchedule",
                                "identifier": [
                                  {
                                    "value": "SOFRACONDHZ01"
                                  }
                                ],
                                "active": true,
                                "actor": [
                                  {
                                    "identifier": {
                                      "use": "official",
                                      "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                                      "value": "99ZZZX"
                                    },
                                    "display": "Dr Dotty McStuffins"
                                  }
                                ]
                              }
                            ],
                            "slot": [
                              {
                                "reference": "#AppointmentSlot"
                              }
                            ],
                            "start": "2025-09-03T02:30:35Z",
                            "end": "2025-09-03T03:30:35Z"
                          },
                          "search": {
                            "mode": "match"
                          }
                        },
                        {
                          "fullUrl": "https://fhir.api.digital.health.nz/R4/Appointment/DHOAppointmentTelehealthExample",
                          "resource": {
                            "resourceType": "Appointment",
                            "id": "DHOAppointmentTelehealthExample",
                            "meta": {
                              "tag": [
                                {
                                  "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                                  "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                                }
                              ],
                              "lastUpdated": "2025-11-11T02:29:24.844Z",
                              "versionId": "3",
                              "profile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                              ],
                              "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                            },
                            "extension": [
                              {
                                "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                                "valueCodeableConcept": {
                                  "coding": [
                                    {
                                      "code": "telehealth",
                                      "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                      "display": "Telehealth"
                                    }
                                  ]
                                }
                              }
                            ],
                            "identifier": [
                              {
                                "value": "#aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
                              }
                            ],
                            "status": "booked",
                            "description": "Telehealth follow-up",
                            "serviceCategory": [
                              {
                                "coding": [
                                  {
                                    "code": "S45",
                                    "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                                    "display": "Orthopaedic Surgery"
                                  }
                                ]
                              }
                            ],
                            "serviceType": [
                              {
                                "coding": [
                                  {
                                    "code": "S45B",
                                    "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                                    "display": "S45B - Fracture Clinic"
                                  }
                                ]
                              }
                            ],
                            "patientInstruction": "Please be available at the scheduled time; ensure your device is charged and you have a stable connection.",
                            "participant": [
                              {
                                "required": "required",
                                "status": "needs-action",
                                "actor": {
                                  "identifier": {
                                    "use": "official",
                                    "system": "https://standards.digital.health.nz/ns/nhi-id",
                                    "value": "ZXP7823"
                                  },
                                  "display": "Carey Carrington"
                                }
                              },
                              {
                                "type": [
                                  {
                                    "coding": [
                                      {
                                        "code": "CON",
                                        "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                        "display": "consultant"
                                      }
                                    ]
                                  }
                                ],
                                "required": "required",
                                "status": "accepted",
                                "actor": {
                                  "identifier": {
                                    "use": "official",
                                    "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                                    "value": "99ZZZX"
                                  },
                                  "display": "Dr Dotty McStuffins"
                                }
                              },
                              {
                                "required": "required",
                                "status": "accepted",
                                "actor": {
                                  "reference": "#DHOClinicLocation"
                                }
                              }
                            ],
                            "contained": [
                              {
                                "resourceType": "Location",
                                "id": "DHOClinicLocation",
                                "meta": {
                                  "profile": [
                                    "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                                  ]
                                },
                                "identifier": [
                                  {
                                    "value": "4211-K01"
                                  }
                                ],
                                "name": "Dunedin Hospital Outpatients, Clinic K01",
                                "partOf": {
                                  "type": "Location",
                                  "identifier": {
                                    "value": "4211",
                                    "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                                  },
                                  "display": "Dunedin Hospital"
                                },
                                "address": {
                                  "use": "work",
                                  "type": "physical",
                                  "line": [
                                    "350 Cumberland Street",
                                    "Dunedin Central"
                                  ],
                                  "city": "Dunedin",
                                  "postalCode": "9016",
                                  "country": "New Zealand"
                                }
                              }
                            ],
                            "start": "2025-09-10T02:30:35Z",
                            "end": "2025-09-10T03:00:35Z"
                          },
                          "search": {
                            "mode": "match"
                          }
                        },
                        {
                          "fullUrl": "https://fhir.api.digital.health.nz/R4/Appointment/DHOAppointmentTelephoneExample",
                          "resource": {
                            "resourceType": "Appointment",
                            "id": "DHOAppointmentTelephoneExample",
                            "meta": {
                              "tag": [
                                {
                                  "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                                  "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                                }
                              ],
                              "lastUpdated": "2025-11-11T02:29:24.844Z",
                              "versionId": "3",
                              "profile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                              ],
                              "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                            },
                            "extension": [
                              {
                                "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                                "valueCodeableConcept": {
                                  "coding": [
                                    {
                                      "code": "telephone",
                                      "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                      "display": "Telephone"
                                    }
                                  ]
                                }
                              }
                            ],
                            "identifier": [
                              {
                                "value": "#bbbbbbbb-cccc-dddd-eeee-ffffffffffff"
                              }
                            ],
                            "status": "booked",
                            "description": "Telephone follow-up",
                            "serviceCategory": [
                              {
                                "coding": [
                                  {
                                    "code": "S45",
                                    "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                                    "display": "Orthopaedic Surgery"
                                  }
                                ]
                              }
                            ],
                            "serviceType": [
                              {
                                "coding": [
                                  {
                                    "code": "S45B",
                                    "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                                    "display": "S45B - Fracture Clinic"
                                  }
                                ]
                              }
                            ],
                            "patientInstruction": "We will call you at the scheduled time. Please keep your phone nearby and ensure voicemail is enabled.",
                            "participant": [
                              {
                                "required": "required",
                                "status": "needs-action",
                                "actor": {
                                  "identifier": {
                                    "use": "official",
                                    "system": "https://standards.digital.health.nz/ns/nhi-id",
                                    "value": "ZXP7823"
                                  },
                                  "display": "Carey Carrington"
                                }
                              },
                              {
                                "type": [
                                  {
                                    "coding": [
                                      {
                                        "code": "CON",
                                        "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                        "display": "consultant"
                                      }
                                    ]
                                  }
                                ],
                                "required": "required",
                                "status": "accepted",
                                "actor": {
                                  "identifier": {
                                    "use": "official",
                                    "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                                    "value": "99ZZZX"
                                  },
                                  "display": "Dr Dotty McStuffins"
                                }
                              },
                              {
                                "required": "required",
                                "status": "accepted",
                                "actor": {
                                  "reference": "#DHOClinicLocation"
                                }
                              }
                            ],
                            "contained": [
                              {
                                "resourceType": "Location",
                                "id": "DHOClinicLocation",
                                "meta": {
                                  "profile": [
                                    "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                                  ]
                                },
                                "identifier": [
                                  {
                                    "value": "4211-K01"
                                  }
                                ],
                                "name": "Dunedin Hospital Outpatients, Clinic K01",
                                "partOf": {
                                  "type": "Location",
                                  "identifier": {
                                    "value": "4211",
                                    "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                                  },
                                  "display": "Dunedin Hospital"
                                },
                                "address": {
                                  "use": "work",
                                  "type": "physical",
                                  "line": [
                                    "350 Cumberland Street",
                                    "Dunedin Central"
                                  ],
                                  "city": "Dunedin",
                                  "postalCode": "9016",
                                  "country": "New Zealand"
                                }
                              }
                            ],
                            "start": "2025-09-17T02:30:35Z",
                            "end": "2025-09-17T02:50:35Z"
                          },
                          "search": {
                            "mode": "match"
                          }
                        },
                        {
                          "fullUrl": "https://fhir.api.digital.health.nz/R4/Appointment/DHOAppointmentUnstructuredExample",
                          "resource": {
                            "resourceType": "Appointment",
                            "id": "DHOAppointmentUnstructuredExample",
                            "meta": {
                              "tag": [
                                {
                                  "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                                  "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                                }
                              ],
                              "lastUpdated": "2025-11-11T02:29:24.844Z",
                              "versionId": "3",
                              "profile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                              ],
                              "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                            },
                            "extension": [
                              {
                                "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                                "valueCodeableConcept": {
                                  "coding": [
                                    {
                                      "code": "in-person",
                                      "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                      "display": "In person"
                                    }
                                  ]
                                }
                              }
                            ],
                            "identifier": [
                              {
                                "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                              }
                            ],
                            "status": "booked",
                            "description": "Physiotherapy Appointment",
                            "serviceCategory": [
                              {
                                "coding": [
                                  {
                                    "code": "A01",
                                    "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                                    "display": "Allied Health and other"
                                  }
                                ]
                              }
                            ],
                            "serviceType": [
                              {
                                "coding": [
                                  {
                                    "code": "A01B",
                                    "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                                    "display": "A01B - Physiotherapy"
                                  }
                                ]
                              }
                            ],
                            "participant": [
                              {
                                "required": "required",
                                "status": "needs-action",
                                "actor": {
                                  "identifier": {
                                    "use": "official",
                                    "system": "https://standards.digital.health.nz/ns/nhi-id",
                                    "value": "ZXP7823"
                                  },
                                  "display": "Carey Carrington"
                                }
                              },
                              {
                                "type": [
                                  {
                                    "coding": [
                                      {
                                        "code": "CON",
                                        "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                        "display": "consultant"
                                      }
                                    ]
                                  }
                                ],
                                "required": "required",
                                "status": "accepted",
                                "actor": {
                                  "identifier": {
                                    "use": "official",
                                    "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                                    "value": "99ZZZX"
                                  },
                                  "display": "Dr Dotty McStuffins"
                                }
                              },
                              {
                                "required": "required",
                                "status": "accepted",
                                "actor": {
                                  "reference": "#DHOClinicLocation"
                                }
                              }
                            ],
                            "contained": [
                              {
                                "resourceType": "Location",
                                "id": "DHOClinicLocation",
                                "meta": {
                                  "profile": [
                                    "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                                  ]
                                },
                                "identifier": [
                                  {
                                    "value": "4211-K01"
                                  }
                                ],
                                "name": "Dunedin Hospital Outpatients, Clinic K01",
                                "partOf": {
                                  "type": "Location",
                                  "identifier": {
                                    "value": "4211",
                                    "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                                  },
                                  "display": "Dunedin Hospital"
                                },
                                "address": {
                                  "use": "work",
                                  "type": "physical",
                                  "line": [
                                    "350 Cumberland Street",
                                    "Dunedin Central"
                                  ],
                                  "city": "Dunedin",
                                  "postalCode": "9016",
                                  "country": "New Zealand"
                                }
                              }
                            ],
                            "start": "2025-09-03T02:30:35Z",
                            "end": "2025-09-03T03:30:35Z"
                          },
                          "search": {
                            "mode": "match"
                          }
                        },
                        {
                          "fullUrl": "https://fhir.api.digital.health.nz/R4/Appointment/OnlineGPAppointmentExample",
                          "resource": {
                            "resourceType": "Appointment",
                            "id": "OnlineGPAppointmentExample",
                            "meta": {
                              "tag": [
                                {
                                  "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                                  "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                                }
                              ],
                              "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F12345-A",
                              "profile": [
                                "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                              ]
                            },
                            "participant": [
                              {
                                "actor": {
                                  "type": "Patient",
                                  "identifier": {
                                    "system": "https://standards.digital.health.nz/ns/nhi-id",
                                    "value": "ZZZ0008"
                                  }
                                },
                                "status": "accepted"
                              }
                            ],
                            "identifier": [
                              {
                                "use": "official",
                                "system": "https://provider-org-name.co.nz/ns/appointment-identifier",
                                "value": "APT123456"
                              }
                            ],
                            "status": "fulfilled",
                            "created": "2025-01-01T09:30:00+13:00",
                            "start": "2025-01-01T10:00:00+13:00",
                            "end": "2025-01-01T10:17:00+13:00",
                            "reasonCode": [
                              {
                                "coding": [
                                  {
                                    "code": "266934004",
                                    "system": "http://snomed.info/sct",
                                    "display": "Transport problem (finding)"
                                  }
                                ]
                              }
                            ]
                          },
                          "search": {
                            "mode": "match"
                          }
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful search operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful search operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful search operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful search operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/Appointment.s"
            ]
          }
        ]
      },
      "post": {
        "summary": "Create Appointment",
        "description": "Create Appointment",
        "tags": [
          "Appointment"
        ],
        "operationId": "createAppointment",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Successful create operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "serviceCategory": {
                          "type": "array",
                          "items": {
                            "description": "A broad categorization of the service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "serviceType": {
                          "type": "array",
                          "items": {
                            "description": "The specific service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "specialty": {
                          "type": "array",
                          "items": {
                            "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "appointmentType": {
                          "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "reasonReference": {
                          "type": "array",
                          "items": {
                            "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "priority": {
                          "type": "integer",
                          "format": "int32",
                          "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "supportingInformation": {
                          "type": "array",
                          "items": {
                            "description": "Additional information to support the appointment provided when making the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "minutesDuration": {
                          "type": "integer",
                          "format": "int32",
                          "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "patientInstruction": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                        },
                        "basedOn": {
                          "type": "array",
                          "items": {
                            "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant"
                      ]
                    },
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              },
                              "minItems": 1
                            }
                          },
                          "required": [
                            "source",
                            "tag"
                          ]
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          },
                          "maxItems": 1,
                          "required": [
                            "system",
                            "value"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "minItems": 1
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant",
                        "meta",
                        "reasonCode"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "Appointment"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              },
                              "minItems": 1
                            }
                          },
                          "required": [
                            "source",
                            "tag"
                          ]
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          },
                          "minItems": 1
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          },
                          "required": [
                            "value"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "proposed",
                            "pending",
                            "booked",
                            "arrived",
                            "fulfilled",
                            "cancelled",
                            "noshow",
                            "entered-in-error",
                            "checked-in",
                            "waitlist"
                          ],
                          "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                        },
                        "cancelationReason": {
                          "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "serviceCategory": {
                          "type": "array",
                          "items": {
                            "description": "A broad categorization of the service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "serviceType": {
                          "type": "array",
                          "items": {
                            "description": "The specific service that is to be performed during this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "specialty": {
                          "type": "array",
                          "items": {
                            "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "appointmentType": {
                          "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "reasonCode": {
                          "type": "array",
                          "items": {
                            "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "reasonReference": {
                          "type": "array",
                          "items": {
                            "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "priority": {
                          "type": "integer",
                          "format": "int32",
                          "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                        },
                        "supportingInformation": {
                          "type": "array",
                          "items": {
                            "description": "Additional information to support the appointment provided when making the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "start": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to take place."
                        },
                        "end": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "Date/Time that the appointment is to conclude."
                        },
                        "minutesDuration": {
                          "type": "integer",
                          "format": "int32",
                          "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                        },
                        "slot": {
                          "type": "array",
                          "items": {
                            "description": "The slots from the participants' schedules that will be filled by the appointment.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                        },
                        "comment": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Additional comments about the appointment."
                        },
                        "patientInstruction": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                        },
                        "basedOn": {
                          "type": "array",
                          "items": {
                            "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "participant": {
                          "type": "array",
                          "items": {
                            "description": "List of participants involved in the appointment.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "type": {
                                "type": "array",
                                "items": {
                                  "description": "Role of participant in the appointment.",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "actor": {
                                "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "required": {
                                "type": "string",
                                "enum": [
                                  "required",
                                  "optional",
                                  "information-only"
                                ],
                                "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "accepted",
                                  "declined",
                                  "tentative",
                                  "needs-action"
                                ],
                                "description": "Participation status of the actor."
                              },
                              "period": {
                                "description": "Participation period of the actor.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              }
                            },
                            "required": [
                              "status"
                            ]
                          },
                          "minItems": 1
                        },
                        "requestedPeriod": {
                          "type": "array",
                          "items": {
                            "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                            "type": "object",
                            "properties": {
                              "start": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The start of the period. The boundary is inclusive."
                              },
                              "end": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                              }
                            }
                          }
                        }
                      },
                      "required": [
                        "resourceType",
                        "status",
                        "participant",
                        "extension"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                    }
                  ]
                },
                "examples": {
                  "Appointment-OnlineGPAppointmentExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "OnlineGPAppointmentExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F12345-A",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                        ]
                      },
                      "participant": [
                        {
                          "actor": {
                            "type": "Patient",
                            "identifier": {
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZZZ0008"
                            }
                          },
                          "status": "accepted"
                        }
                      ],
                      "identifier": [
                        {
                          "use": "official",
                          "system": "https://provider-org-name.co.nz/ns/appointment-identifier",
                          "value": "APT123456"
                        }
                      ],
                      "status": "fulfilled",
                      "created": "2025-01-01T09:30:00+13:00",
                      "start": "2025-01-01T10:00:00+13:00",
                      "end": "2025-01-01T10:17:00+13:00",
                      "reasonCode": [
                        {
                          "coding": [
                            {
                              "code": "266934004",
                              "system": "http://snomed.info/sct",
                              "display": "Transport problem (finding)"
                            }
                          ]
                        }
                      ]
                    }
                  },
                  "Appointment-DHOAppointmentClinicExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentClinicExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "in-person",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "In person"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                        }
                      ],
                      "status": "booked",
                      "description": "DH Fracture Consultant",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "Bring all medications you are currently taking on your admission to hospital.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "ATND",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "attender"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        },
                        {
                          "resourceType": "Slot",
                          "id": "AppointmentSlot",
                          "status": "busy",
                          "start": "2025-09-03T02:30:35Z",
                          "end": "2025-09-03T03:30:35Z",
                          "schedule": {
                            "reference": "#ClinicSchedule"
                          }
                        },
                        {
                          "resourceType": "Schedule",
                          "id": "ClinicSchedule",
                          "identifier": [
                            {
                              "value": "SOFRACONDHZ01"
                            }
                          ],
                          "active": true,
                          "actor": [
                            {
                              "identifier": {
                                "use": "official",
                                "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                                "value": "99ZZZX"
                              },
                              "display": "Dr Dotty McStuffins"
                            }
                          ]
                        }
                      ],
                      "slot": [
                        {
                          "reference": "#AppointmentSlot"
                        }
                      ],
                      "start": "2025-09-03T02:30:35Z",
                      "end": "2025-09-03T03:30:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentTelehealthExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentTelehealthExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "telehealth",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "Telehealth"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
                        }
                      ],
                      "status": "booked",
                      "description": "Telehealth follow-up",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "Please be available at the scheduled time; ensure your device is charged and you have a stable connection.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-10T02:30:35Z",
                      "end": "2025-09-10T03:00:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentTelephoneExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentTelephoneExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "telephone",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "Telephone"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#bbbbbbbb-cccc-dddd-eeee-ffffffffffff"
                        }
                      ],
                      "status": "booked",
                      "description": "Telephone follow-up",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "S45",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Orthopaedic Surgery"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "S45B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "S45B - Fracture Clinic"
                            }
                          ]
                        }
                      ],
                      "patientInstruction": "We will call you at the scheduled time. Please keep your phone nearby and ensure voicemail is enabled.",
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-17T02:30:35Z",
                      "end": "2025-09-17T02:50:35Z"
                    }
                  },
                  "Appointment-DHOAppointmentUnstructuredExample": {
                    "value": {
                      "resourceType": "Appointment",
                      "id": "DHOAppointmentUnstructuredExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "3",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "extension": [
                        {
                          "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "code": "in-person",
                                "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                                "display": "In person"
                              }
                            ]
                          }
                        }
                      ],
                      "identifier": [
                        {
                          "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                        }
                      ],
                      "status": "booked",
                      "description": "Physiotherapy Appointment",
                      "serviceCategory": [
                        {
                          "coding": [
                            {
                              "code": "A01",
                              "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                              "display": "Allied Health and other"
                            }
                          ]
                        }
                      ],
                      "serviceType": [
                        {
                          "coding": [
                            {
                              "code": "A01B",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                              "display": "A01B - Physiotherapy"
                            }
                          ]
                        }
                      ],
                      "participant": [
                        {
                          "required": "required",
                          "status": "needs-action",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/nhi-id",
                              "value": "ZXP7823"
                            },
                            "display": "Carey Carrington"
                          }
                        },
                        {
                          "type": [
                            {
                              "coding": [
                                {
                                  "code": "CON",
                                  "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                  "display": "consultant"
                                }
                              ]
                            }
                          ],
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        },
                        {
                          "required": "required",
                          "status": "accepted",
                          "actor": {
                            "reference": "#DHOClinicLocation"
                          }
                        }
                      ],
                      "contained": [
                        {
                          "resourceType": "Location",
                          "id": "DHOClinicLocation",
                          "meta": {
                            "profile": [
                              "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                            ]
                          },
                          "identifier": [
                            {
                              "value": "4211-K01"
                            }
                          ],
                          "name": "Dunedin Hospital Outpatients, Clinic K01",
                          "partOf": {
                            "type": "Location",
                            "identifier": {
                              "value": "4211",
                              "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                            },
                            "display": "Dunedin Hospital"
                          },
                          "address": {
                            "use": "work",
                            "type": "physical",
                            "line": [
                              "350 Cumberland Street",
                              "Dunedin Central"
                            ],
                            "city": "Dunedin",
                            "postalCode": "9016",
                            "country": "New Zealand"
                          }
                        }
                      ],
                      "start": "2025-09-03T02:30:35Z",
                      "end": "2025-09-03T03:30:35Z"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful create operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful create operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful create operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful create operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "requestBody": {
          "description": "Appointment to create",
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "resourceType": {
                        "type": "string",
                        "enum": [
                          "Appointment"
                        ]
                      },
                      "id": {
                        "type": "string",
                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                        "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                      },
                      "meta": {
                        "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                        "type": "object",
                        "properties": {
                          "versionId": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                          },
                          "lastUpdated": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                            "description": "When the resource last changed &ndash; e.g. when the version changed."
                          },
                          "source": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                          },
                          "profile": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                            }
                          },
                          "security": {
                            "type": "array",
                            "items": {
                              "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "tag": {
                            "type": "array",
                            "items": {
                              "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          }
                        }
                      },
                      "implicitRules": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                      },
                      "language": {
                        "type": "string",
                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                        "description": "The base language in which the resource is written."
                      },
                      "text": {
                        "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                        "type": "object",
                        "properties": {
                          "status": {
                            "type": "string",
                            "enum": [
                              "generated",
                              "extensions",
                              "additional",
                              "empty"
                            ],
                            "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                          },
                          "div": {
                            "type": "string",
                            "description": "The actual narrative content, a stripped down version of XHTML."
                          }
                        },
                        "required": [
                          "status",
                          "div"
                        ]
                      },
                      "contained": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "resourceType": {
                              "type": "string",
                              "enum": [
                                "Account",
                                "ActivityDefinition",
                                "AdverseEvent",
                                "AllergyIntolerance",
                                "Appointment",
                                "AppointmentResponse",
                                "AuditEvent",
                                "Basic",
                                "Binary",
                                "BiologicallyDerivedProduct",
                                "BodyStructure",
                                "Bundle",
                                "CapabilityStatement",
                                "CarePlan",
                                "CareTeam",
                                "CatalogEntry",
                                "ChargeItem",
                                "ChargeItemDefinition",
                                "Claim",
                                "ClaimResponse",
                                "ClinicalImpression",
                                "CodeSystem",
                                "Communication",
                                "CommunicationRequest",
                                "CompartmentDefinition",
                                "Composition",
                                "ConceptMap",
                                "Condition",
                                "Consent",
                                "Contract",
                                "Coverage",
                                "CoverageEligibilityRequest",
                                "CoverageEligibilityResponse",
                                "DetectedIssue",
                                "Device",
                                "DeviceDefinition",
                                "DeviceMetric",
                                "DeviceRequest",
                                "DeviceUseStatement",
                                "DiagnosticReport",
                                "DocumentManifest",
                                "DocumentReference",
                                "DomainResource",
                                "EffectEvidenceSynthesis",
                                "Encounter",
                                "Endpoint",
                                "EnrollmentRequest",
                                "EnrollmentResponse",
                                "EpisodeOfCare",
                                "EventDefinition",
                                "Evidence",
                                "EvidenceVariable",
                                "ExampleScenario",
                                "ExplanationOfBenefit",
                                "FamilyMemberHistory",
                                "Flag",
                                "Goal",
                                "GraphDefinition",
                                "Group",
                                "GuidanceResponse",
                                "HealthcareService",
                                "ImagingStudy",
                                "Immunization",
                                "ImmunizationEvaluation",
                                "ImmunizationRecommendation",
                                "ImplementationGuide",
                                "InsurancePlan",
                                "Invoice",
                                "Library",
                                "Linkage",
                                "List",
                                "Location",
                                "Measure",
                                "MeasureReport",
                                "Media",
                                "Medication",
                                "MedicationAdministration",
                                "MedicationDispense",
                                "MedicationKnowledge",
                                "MedicationRequest",
                                "MedicationStatement",
                                "MedicinalProduct",
                                "MedicinalProductAuthorization",
                                "MedicinalProductContraindication",
                                "MedicinalProductIndication",
                                "MedicinalProductIngredient",
                                "MedicinalProductInteraction",
                                "MedicinalProductManufactured",
                                "MedicinalProductPackaged",
                                "MedicinalProductPharmaceutical",
                                "MedicinalProductUndesirableEffect",
                                "MessageDefinition",
                                "MessageHeader",
                                "MolecularSequence",
                                "NamingSystem",
                                "NutritionOrder",
                                "Observation",
                                "ObservationDefinition",
                                "OperationDefinition",
                                "OperationOutcome",
                                "Organization",
                                "OrganizationAffiliation",
                                "Parameters",
                                "Patient",
                                "PaymentNotice",
                                "PaymentReconciliation",
                                "Person",
                                "PlanDefinition",
                                "Practitioner",
                                "PractitionerRole",
                                "Procedure",
                                "Provenance",
                                "Questionnaire",
                                "QuestionnaireResponse",
                                "RelatedPerson",
                                "RequestGroup",
                                "ResearchDefinition",
                                "ResearchElementDefinition",
                                "ResearchStudy",
                                "ResearchSubject",
                                "Resource",
                                "RiskAssessment",
                                "RiskEvidenceSynthesis",
                                "Schedule",
                                "SearchParameter",
                                "ServiceRequest",
                                "Slot",
                                "Specimen",
                                "SpecimenDefinition",
                                "StructureDefinition",
                                "StructureMap",
                                "Subscription",
                                "Substance",
                                "SubstanceNucleicAcid",
                                "SubstancePolymer",
                                "SubstanceProtein",
                                "SubstanceReferenceInformation",
                                "SubstanceSourceMaterial",
                                "SubstanceSpecification",
                                "SupplyDelivery",
                                "SupplyRequest",
                                "Task",
                                "TerminologyCapabilities",
                                "TestReport",
                                "TestScript",
                                "ValueSet",
                                "VerificationResult",
                                "VisionPrescription"
                              ]
                            },
                            "id": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                            },
                            "meta": {
                              "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                              "type": "object",
                              "properties": {
                                "versionId": {
                                  "type": "string",
                                  "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                  "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                },
                                "lastUpdated": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                  "description": "When the resource last changed &ndash; e.g. when the version changed."
                                },
                                "source": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                },
                                "profile": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                  }
                                },
                                "security": {
                                  "type": "array",
                                  "items": {
                                    "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "tag": {
                                  "type": "array",
                                  "items": {
                                    "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                }
                              }
                            },
                            "implicitRules": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                            },
                            "language": {
                              "type": "string",
                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                              "description": "The base language in which the resource is written."
                            }
                          },
                          "required": [
                            "resourceType"
                          ],
                          "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                        }
                      },
                      "extension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "modifierExtension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "identifier": {
                        "type": "array",
                        "items": {
                          "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                          "type": "object",
                          "properties": {
                            "use": {
                              "type": "string",
                              "enum": [
                                "usual",
                                "official",
                                "temp",
                                "secondary",
                                "old"
                              ],
                              "description": "The purpose of this identifier."
                            },
                            "type": {
                              "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                            },
                            "value": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                            },
                            "period": {
                              "description": "Time period during which identifier is/was valid for use.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            },
                            "assigner": {
                              "description": "Organization that issued/manages the identifier.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            }
                          }
                        }
                      },
                      "status": {
                        "type": "string",
                        "enum": [
                          "proposed",
                          "pending",
                          "booked",
                          "arrived",
                          "fulfilled",
                          "cancelled",
                          "noshow",
                          "entered-in-error",
                          "checked-in",
                          "waitlist"
                        ],
                        "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                      },
                      "cancelationReason": {
                        "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "serviceCategory": {
                        "type": "array",
                        "items": {
                          "description": "A broad categorization of the service that is to be performed during this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "serviceType": {
                        "type": "array",
                        "items": {
                          "description": "The specific service that is to be performed during this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "specialty": {
                        "type": "array",
                        "items": {
                          "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "appointmentType": {
                        "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "reasonCode": {
                        "type": "array",
                        "items": {
                          "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "reasonReference": {
                        "type": "array",
                        "items": {
                          "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "priority": {
                        "type": "integer",
                        "format": "int32",
                        "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                      },
                      "description": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                      },
                      "supportingInformation": {
                        "type": "array",
                        "items": {
                          "description": "Additional information to support the appointment provided when making the appointment.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "start": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to take place."
                      },
                      "end": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to conclude."
                      },
                      "minutesDuration": {
                        "type": "integer",
                        "format": "int32",
                        "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                      },
                      "slot": {
                        "type": "array",
                        "items": {
                          "description": "The slots from the participants' schedules that will be filled by the appointment.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "created": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                        "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                      },
                      "comment": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "Additional comments about the appointment."
                      },
                      "patientInstruction": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                      },
                      "basedOn": {
                        "type": "array",
                        "items": {
                          "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "participant": {
                        "type": "array",
                        "items": {
                          "description": "List of participants involved in the appointment.",
                          "type": "object",
                          "properties": {
                            "modifierExtension": {
                              "type": "array",
                              "items": {
                                "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                "type": "object",
                                "additionalProperties": true
                              }
                            },
                            "type": {
                              "type": "array",
                              "items": {
                                "description": "Role of participant in the appointment.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              }
                            },
                            "actor": {
                              "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            },
                            "required": {
                              "type": "string",
                              "enum": [
                                "required",
                                "optional",
                                "information-only"
                              ],
                              "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                            },
                            "status": {
                              "type": "string",
                              "enum": [
                                "accepted",
                                "declined",
                                "tentative",
                                "needs-action"
                              ],
                              "description": "Participation status of the actor."
                            },
                            "period": {
                              "description": "Participation period of the actor.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            }
                          },
                          "required": [
                            "status"
                          ]
                        },
                        "minItems": 1
                      },
                      "requestedPeriod": {
                        "type": "array",
                        "items": {
                          "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        }
                      }
                    },
                    "required": [
                      "resourceType",
                      "status",
                      "participant"
                    ]
                  },
                  {
                    "type": "object",
                    "properties": {
                      "resourceType": {
                        "type": "string",
                        "enum": [
                          "Appointment"
                        ]
                      },
                      "id": {
                        "type": "string",
                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                        "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                      },
                      "meta": {
                        "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                        "type": "object",
                        "properties": {
                          "versionId": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                          },
                          "lastUpdated": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                            "description": "When the resource last changed &ndash; e.g. when the version changed."
                          },
                          "source": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                          },
                          "profile": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                            }
                          },
                          "security": {
                            "type": "array",
                            "items": {
                              "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "tag": {
                            "type": "array",
                            "items": {
                              "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            },
                            "minItems": 1
                          }
                        },
                        "required": [
                          "source",
                          "tag"
                        ]
                      },
                      "implicitRules": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                      },
                      "language": {
                        "type": "string",
                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                        "description": "The base language in which the resource is written."
                      },
                      "text": {
                        "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                        "type": "object",
                        "properties": {
                          "status": {
                            "type": "string",
                            "enum": [
                              "generated",
                              "extensions",
                              "additional",
                              "empty"
                            ],
                            "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                          },
                          "div": {
                            "type": "string",
                            "description": "The actual narrative content, a stripped down version of XHTML."
                          }
                        },
                        "required": [
                          "status",
                          "div"
                        ]
                      },
                      "extension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "modifierExtension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "identifier": {
                        "type": "array",
                        "items": {
                          "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                          "type": "object",
                          "properties": {
                            "use": {
                              "type": "string",
                              "enum": [
                                "usual",
                                "official",
                                "temp",
                                "secondary",
                                "old"
                              ],
                              "description": "The purpose of this identifier."
                            },
                            "type": {
                              "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                            },
                            "value": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                            },
                            "period": {
                              "description": "Time period during which identifier is/was valid for use.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            },
                            "assigner": {
                              "description": "Organization that issued/manages the identifier.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            }
                          }
                        },
                        "maxItems": 1,
                        "required": [
                          "system",
                          "value"
                        ]
                      },
                      "status": {
                        "type": "string",
                        "enum": [
                          "proposed",
                          "pending",
                          "booked",
                          "arrived",
                          "fulfilled",
                          "cancelled",
                          "noshow",
                          "entered-in-error",
                          "checked-in",
                          "waitlist"
                        ],
                        "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                      },
                      "cancelationReason": {
                        "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "reasonCode": {
                        "type": "array",
                        "items": {
                          "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "minItems": 1
                      },
                      "description": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                      },
                      "start": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to take place."
                      },
                      "end": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to conclude."
                      },
                      "slot": {
                        "type": "array",
                        "items": {
                          "description": "The slots from the participants' schedules that will be filled by the appointment.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "created": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                        "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                      },
                      "comment": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "Additional comments about the appointment."
                      },
                      "participant": {
                        "type": "array",
                        "items": {
                          "description": "List of participants involved in the appointment.",
                          "type": "object",
                          "properties": {
                            "modifierExtension": {
                              "type": "array",
                              "items": {
                                "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                "type": "object",
                                "additionalProperties": true
                              }
                            },
                            "type": {
                              "type": "array",
                              "items": {
                                "description": "Role of participant in the appointment.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              }
                            },
                            "actor": {
                              "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            },
                            "required": {
                              "type": "string",
                              "enum": [
                                "required",
                                "optional",
                                "information-only"
                              ],
                              "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                            },
                            "status": {
                              "type": "string",
                              "enum": [
                                "accepted",
                                "declined",
                                "tentative",
                                "needs-action"
                              ],
                              "description": "Participation status of the actor."
                            },
                            "period": {
                              "description": "Participation period of the actor.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            }
                          },
                          "required": [
                            "status"
                          ]
                        },
                        "minItems": 1
                      },
                      "requestedPeriod": {
                        "type": "array",
                        "items": {
                          "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        }
                      }
                    },
                    "required": [
                      "resourceType",
                      "status",
                      "participant",
                      "meta",
                      "reasonCode"
                    ],
                    "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                  },
                  {
                    "type": "object",
                    "properties": {
                      "resourceType": {
                        "type": "string",
                        "enum": [
                          "Appointment"
                        ]
                      },
                      "id": {
                        "type": "string",
                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                        "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                      },
                      "meta": {
                        "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                        "type": "object",
                        "properties": {
                          "versionId": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                          },
                          "lastUpdated": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                            "description": "When the resource last changed &ndash; e.g. when the version changed."
                          },
                          "source": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                          },
                          "profile": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                            }
                          },
                          "security": {
                            "type": "array",
                            "items": {
                              "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "tag": {
                            "type": "array",
                            "items": {
                              "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            },
                            "minItems": 1
                          }
                        },
                        "required": [
                          "source",
                          "tag"
                        ]
                      },
                      "implicitRules": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                      },
                      "language": {
                        "type": "string",
                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                        "description": "The base language in which the resource is written."
                      },
                      "text": {
                        "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                        "type": "object",
                        "properties": {
                          "status": {
                            "type": "string",
                            "enum": [
                              "generated",
                              "extensions",
                              "additional",
                              "empty"
                            ],
                            "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                          },
                          "div": {
                            "type": "string",
                            "description": "The actual narrative content, a stripped down version of XHTML."
                          }
                        },
                        "required": [
                          "status",
                          "div"
                        ]
                      },
                      "contained": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "resourceType": {
                              "type": "string",
                              "enum": [
                                "Account",
                                "ActivityDefinition",
                                "AdverseEvent",
                                "AllergyIntolerance",
                                "Appointment",
                                "AppointmentResponse",
                                "AuditEvent",
                                "Basic",
                                "Binary",
                                "BiologicallyDerivedProduct",
                                "BodyStructure",
                                "Bundle",
                                "CapabilityStatement",
                                "CarePlan",
                                "CareTeam",
                                "CatalogEntry",
                                "ChargeItem",
                                "ChargeItemDefinition",
                                "Claim",
                                "ClaimResponse",
                                "ClinicalImpression",
                                "CodeSystem",
                                "Communication",
                                "CommunicationRequest",
                                "CompartmentDefinition",
                                "Composition",
                                "ConceptMap",
                                "Condition",
                                "Consent",
                                "Contract",
                                "Coverage",
                                "CoverageEligibilityRequest",
                                "CoverageEligibilityResponse",
                                "DetectedIssue",
                                "Device",
                                "DeviceDefinition",
                                "DeviceMetric",
                                "DeviceRequest",
                                "DeviceUseStatement",
                                "DiagnosticReport",
                                "DocumentManifest",
                                "DocumentReference",
                                "DomainResource",
                                "EffectEvidenceSynthesis",
                                "Encounter",
                                "Endpoint",
                                "EnrollmentRequest",
                                "EnrollmentResponse",
                                "EpisodeOfCare",
                                "EventDefinition",
                                "Evidence",
                                "EvidenceVariable",
                                "ExampleScenario",
                                "ExplanationOfBenefit",
                                "FamilyMemberHistory",
                                "Flag",
                                "Goal",
                                "GraphDefinition",
                                "Group",
                                "GuidanceResponse",
                                "HealthcareService",
                                "ImagingStudy",
                                "Immunization",
                                "ImmunizationEvaluation",
                                "ImmunizationRecommendation",
                                "ImplementationGuide",
                                "InsurancePlan",
                                "Invoice",
                                "Library",
                                "Linkage",
                                "List",
                                "Location",
                                "Measure",
                                "MeasureReport",
                                "Media",
                                "Medication",
                                "MedicationAdministration",
                                "MedicationDispense",
                                "MedicationKnowledge",
                                "MedicationRequest",
                                "MedicationStatement",
                                "MedicinalProduct",
                                "MedicinalProductAuthorization",
                                "MedicinalProductContraindication",
                                "MedicinalProductIndication",
                                "MedicinalProductIngredient",
                                "MedicinalProductInteraction",
                                "MedicinalProductManufactured",
                                "MedicinalProductPackaged",
                                "MedicinalProductPharmaceutical",
                                "MedicinalProductUndesirableEffect",
                                "MessageDefinition",
                                "MessageHeader",
                                "MolecularSequence",
                                "NamingSystem",
                                "NutritionOrder",
                                "Observation",
                                "ObservationDefinition",
                                "OperationDefinition",
                                "OperationOutcome",
                                "Organization",
                                "OrganizationAffiliation",
                                "Parameters",
                                "Patient",
                                "PaymentNotice",
                                "PaymentReconciliation",
                                "Person",
                                "PlanDefinition",
                                "Practitioner",
                                "PractitionerRole",
                                "Procedure",
                                "Provenance",
                                "Questionnaire",
                                "QuestionnaireResponse",
                                "RelatedPerson",
                                "RequestGroup",
                                "ResearchDefinition",
                                "ResearchElementDefinition",
                                "ResearchStudy",
                                "ResearchSubject",
                                "Resource",
                                "RiskAssessment",
                                "RiskEvidenceSynthesis",
                                "Schedule",
                                "SearchParameter",
                                "ServiceRequest",
                                "Slot",
                                "Specimen",
                                "SpecimenDefinition",
                                "StructureDefinition",
                                "StructureMap",
                                "Subscription",
                                "Substance",
                                "SubstanceNucleicAcid",
                                "SubstancePolymer",
                                "SubstanceProtein",
                                "SubstanceReferenceInformation",
                                "SubstanceSourceMaterial",
                                "SubstanceSpecification",
                                "SupplyDelivery",
                                "SupplyRequest",
                                "Task",
                                "TerminologyCapabilities",
                                "TestReport",
                                "TestScript",
                                "ValueSet",
                                "VerificationResult",
                                "VisionPrescription"
                              ]
                            },
                            "id": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                            },
                            "meta": {
                              "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                              "type": "object",
                              "properties": {
                                "versionId": {
                                  "type": "string",
                                  "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                  "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                },
                                "lastUpdated": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                  "description": "When the resource last changed &ndash; e.g. when the version changed."
                                },
                                "source": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                },
                                "profile": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                  }
                                },
                                "security": {
                                  "type": "array",
                                  "items": {
                                    "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "tag": {
                                  "type": "array",
                                  "items": {
                                    "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                }
                              }
                            },
                            "implicitRules": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                            },
                            "language": {
                              "type": "string",
                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                              "description": "The base language in which the resource is written."
                            }
                          },
                          "required": [
                            "resourceType"
                          ],
                          "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                        }
                      },
                      "extension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                          "type": "object",
                          "additionalProperties": true
                        },
                        "minItems": 1
                      },
                      "modifierExtension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "identifier": {
                        "type": "array",
                        "items": {
                          "description": "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).",
                          "type": "object",
                          "properties": {
                            "use": {
                              "type": "string",
                              "enum": [
                                "usual",
                                "official",
                                "temp",
                                "secondary",
                                "old"
                              ],
                              "description": "The purpose of this identifier."
                            },
                            "type": {
                              "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                            },
                            "value": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                            },
                            "period": {
                              "description": "Time period during which identifier is/was valid for use.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            },
                            "assigner": {
                              "description": "Organization that issued/manages the identifier.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            }
                          }
                        },
                        "required": [
                          "value"
                        ]
                      },
                      "status": {
                        "type": "string",
                        "enum": [
                          "proposed",
                          "pending",
                          "booked",
                          "arrived",
                          "fulfilled",
                          "cancelled",
                          "noshow",
                          "entered-in-error",
                          "checked-in",
                          "waitlist"
                        ],
                        "description": "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status."
                      },
                      "cancelationReason": {
                        "description": "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "serviceCategory": {
                        "type": "array",
                        "items": {
                          "description": "A broad categorization of the service that is to be performed during this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "serviceType": {
                        "type": "array",
                        "items": {
                          "description": "The specific service that is to be performed during this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "specialty": {
                        "type": "array",
                        "items": {
                          "description": "The specialty of a practitioner that would be required to perform the service requested in this appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "appointmentType": {
                        "description": "The style of appointment or patient that has been booked in the slot (not service type).",
                        "type": "object",
                        "properties": {
                          "coding": {
                            "type": "array",
                            "items": {
                              "description": "A reference to a code defined by a terminology system.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "text": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                          }
                        }
                      },
                      "reasonCode": {
                        "type": "array",
                        "items": {
                          "description": "The coded reason that this appointment is being scheduled. This is more clinical than administrative.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        }
                      },
                      "reasonReference": {
                        "type": "array",
                        "items": {
                          "description": "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "priority": {
                        "type": "integer",
                        "format": "int32",
                        "description": "The priority of the appointment. Can be used to make informed decisions if needing to re&ndash;prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)."
                      },
                      "description": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field."
                      },
                      "supportingInformation": {
                        "type": "array",
                        "items": {
                          "description": "Additional information to support the appointment provided when making the appointment.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "start": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to take place."
                      },
                      "end": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                        "description": "Date/Time that the appointment is to conclude."
                      },
                      "minutesDuration": {
                        "type": "integer",
                        "format": "int32",
                        "description": "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times.  For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work.  Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end."
                      },
                      "slot": {
                        "type": "array",
                        "items": {
                          "description": "The slots from the participants' schedules that will be filled by the appointment.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "created": {
                        "type": "string",
                        "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                        "description": "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment."
                      },
                      "comment": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "Additional comments about the appointment."
                      },
                      "patientInstruction": {
                        "type": "string",
                        "pattern": "[ \\r\\n\\t\\S]+",
                        "description": "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)."
                      },
                      "basedOn": {
                        "type": "array",
                        "items": {
                          "description": "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        }
                      },
                      "participant": {
                        "type": "array",
                        "items": {
                          "description": "List of participants involved in the appointment.",
                          "type": "object",
                          "properties": {
                            "modifierExtension": {
                              "type": "array",
                              "items": {
                                "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                "type": "object",
                                "additionalProperties": true
                              }
                            },
                            "type": {
                              "type": "array",
                              "items": {
                                "description": "Role of participant in the appointment.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              }
                            },
                            "actor": {
                              "description": "A Person, Location/HealthcareService or Device that is participating in the appointment.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            },
                            "required": {
                              "type": "string",
                              "enum": [
                                "required",
                                "optional",
                                "information-only"
                              ],
                              "description": "Whether this participant is required to be present at the meeting. This covers a use&ndash;case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present."
                            },
                            "status": {
                              "type": "string",
                              "enum": [
                                "accepted",
                                "declined",
                                "tentative",
                                "needs-action"
                              ],
                              "description": "Participation status of the actor."
                            },
                            "period": {
                              "description": "Participation period of the actor.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            }
                          },
                          "required": [
                            "status"
                          ]
                        },
                        "minItems": 1
                      },
                      "requestedPeriod": {
                        "type": "array",
                        "items": {
                          "description": "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        }
                      }
                    },
                    "required": [
                      "resourceType",
                      "status",
                      "participant",
                      "extension"
                    ],
                    "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                  }
                ]
              },
              "examples": {
                "Appointment-OnlineGPAppointmentExample-create": {
                  "value": {
                    "resourceType": "Appointment",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F12345-A",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OnlineGPAppointment"
                      ]
                    },
                    "participant": [
                      {
                        "actor": {
                          "type": "Patient",
                          "identifier": {
                            "system": "https://standards.digital.health.nz/ns/nhi-id",
                            "value": "ZZZ0008"
                          }
                        },
                        "status": "accepted"
                      }
                    ],
                    "identifier": [
                      {
                        "use": "official",
                        "system": "https://provider-org-name.co.nz/ns/appointment-identifier",
                        "value": "APT123456"
                      }
                    ],
                    "status": "fulfilled",
                    "created": "2025-01-01T09:30:00+13:00",
                    "start": "2025-01-01T10:00:00+13:00",
                    "end": "2025-01-01T10:17:00+13:00",
                    "reasonCode": [
                      {
                        "coding": [
                          {
                            "code": "266934004",
                            "system": "http://snomed.info/sct",
                            "display": "Transport problem (finding)"
                          }
                        ]
                      }
                    ]
                  }
                },
                "Appointment-DHOAppointmentClinicExample-create": {
                  "value": {
                    "resourceType": "Appointment",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "lastUpdated": "2025-11-11T02:29:24.844Z",
                      "versionId": "3",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                    },
                    "extension": [
                      {
                        "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                        "valueCodeableConcept": {
                          "coding": [
                            {
                              "code": "in-person",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                              "display": "In person"
                            }
                          ]
                        }
                      }
                    ],
                    "identifier": [
                      {
                        "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                      }
                    ],
                    "status": "booked",
                    "description": "DH Fracture Consultant",
                    "serviceCategory": [
                      {
                        "coding": [
                          {
                            "code": "S45",
                            "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                            "display": "Orthopaedic Surgery"
                          }
                        ]
                      }
                    ],
                    "serviceType": [
                      {
                        "coding": [
                          {
                            "code": "S45B",
                            "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                            "display": "S45B - Fracture Clinic"
                          }
                        ]
                      }
                    ],
                    "patientInstruction": "Bring all medications you are currently taking on your admission to hospital.",
                    "participant": [
                      {
                        "required": "required",
                        "status": "needs-action",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/nhi-id",
                            "value": "ZXP7823"
                          },
                          "display": "Carey Carrington"
                        }
                      },
                      {
                        "type": [
                          {
                            "coding": [
                              {
                                "code": "ATND",
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                "display": "attender"
                              }
                            ]
                          }
                        ],
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                            "value": "99ZZZX"
                          },
                          "display": "Dr Dotty McStuffins"
                        }
                      },
                      {
                        "type": [
                          {
                            "coding": [
                              {
                                "code": "CON",
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                "display": "consultant"
                              }
                            ]
                          }
                        ],
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                            "value": "99ZZZX"
                          },
                          "display": "Dr Dotty McStuffins"
                        }
                      },
                      {
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "reference": "#DHOClinicLocation"
                        }
                      }
                    ],
                    "contained": [
                      {
                        "resourceType": "Location",
                        "id": "DHOClinicLocation",
                        "meta": {
                          "profile": [
                            "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                          ]
                        },
                        "identifier": [
                          {
                            "value": "4211-K01"
                          }
                        ],
                        "name": "Dunedin Hospital Outpatients, Clinic K01",
                        "partOf": {
                          "type": "Location",
                          "identifier": {
                            "value": "4211",
                            "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                          },
                          "display": "Dunedin Hospital"
                        },
                        "address": {
                          "use": "work",
                          "type": "physical",
                          "line": [
                            "350 Cumberland Street",
                            "Dunedin Central"
                          ],
                          "city": "Dunedin",
                          "postalCode": "9016",
                          "country": "New Zealand"
                        }
                      },
                      {
                        "resourceType": "Slot",
                        "id": "AppointmentSlot",
                        "status": "busy",
                        "start": "2025-09-03T02:30:35Z",
                        "end": "2025-09-03T03:30:35Z",
                        "schedule": {
                          "reference": "#ClinicSchedule"
                        }
                      },
                      {
                        "resourceType": "Schedule",
                        "id": "ClinicSchedule",
                        "identifier": [
                          {
                            "value": "SOFRACONDHZ01"
                          }
                        ],
                        "active": true,
                        "actor": [
                          {
                            "identifier": {
                              "use": "official",
                              "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                              "value": "99ZZZX"
                            },
                            "display": "Dr Dotty McStuffins"
                          }
                        ]
                      }
                    ],
                    "slot": [
                      {
                        "reference": "#AppointmentSlot"
                      }
                    ],
                    "start": "2025-09-03T02:30:35Z",
                    "end": "2025-09-03T03:30:35Z"
                  }
                },
                "Appointment-DHOAppointmentTelehealthExample-create": {
                  "value": {
                    "resourceType": "Appointment",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "lastUpdated": "2025-11-11T02:29:24.844Z",
                      "versionId": "3",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                    },
                    "extension": [
                      {
                        "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                        "valueCodeableConcept": {
                          "coding": [
                            {
                              "code": "telehealth",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                              "display": "Telehealth"
                            }
                          ]
                        }
                      }
                    ],
                    "identifier": [
                      {
                        "value": "#aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
                      }
                    ],
                    "status": "booked",
                    "description": "Telehealth follow-up",
                    "serviceCategory": [
                      {
                        "coding": [
                          {
                            "code": "S45",
                            "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                            "display": "Orthopaedic Surgery"
                          }
                        ]
                      }
                    ],
                    "serviceType": [
                      {
                        "coding": [
                          {
                            "code": "S45B",
                            "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                            "display": "S45B - Fracture Clinic"
                          }
                        ]
                      }
                    ],
                    "patientInstruction": "Please be available at the scheduled time; ensure your device is charged and you have a stable connection.",
                    "participant": [
                      {
                        "required": "required",
                        "status": "needs-action",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/nhi-id",
                            "value": "ZXP7823"
                          },
                          "display": "Carey Carrington"
                        }
                      },
                      {
                        "type": [
                          {
                            "coding": [
                              {
                                "code": "CON",
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                "display": "consultant"
                              }
                            ]
                          }
                        ],
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                            "value": "99ZZZX"
                          },
                          "display": "Dr Dotty McStuffins"
                        }
                      },
                      {
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "reference": "#DHOClinicLocation"
                        }
                      }
                    ],
                    "contained": [
                      {
                        "resourceType": "Location",
                        "id": "DHOClinicLocation",
                        "meta": {
                          "profile": [
                            "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                          ]
                        },
                        "identifier": [
                          {
                            "value": "4211-K01"
                          }
                        ],
                        "name": "Dunedin Hospital Outpatients, Clinic K01",
                        "partOf": {
                          "type": "Location",
                          "identifier": {
                            "value": "4211",
                            "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                          },
                          "display": "Dunedin Hospital"
                        },
                        "address": {
                          "use": "work",
                          "type": "physical",
                          "line": [
                            "350 Cumberland Street",
                            "Dunedin Central"
                          ],
                          "city": "Dunedin",
                          "postalCode": "9016",
                          "country": "New Zealand"
                        }
                      }
                    ],
                    "start": "2025-09-10T02:30:35Z",
                    "end": "2025-09-10T03:00:35Z"
                  }
                },
                "Appointment-DHOAppointmentTelephoneExample-create": {
                  "value": {
                    "resourceType": "Appointment",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "lastUpdated": "2025-11-11T02:29:24.844Z",
                      "versionId": "3",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                    },
                    "extension": [
                      {
                        "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                        "valueCodeableConcept": {
                          "coding": [
                            {
                              "code": "telephone",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                              "display": "Telephone"
                            }
                          ]
                        }
                      }
                    ],
                    "identifier": [
                      {
                        "value": "#bbbbbbbb-cccc-dddd-eeee-ffffffffffff"
                      }
                    ],
                    "status": "booked",
                    "description": "Telephone follow-up",
                    "serviceCategory": [
                      {
                        "coding": [
                          {
                            "code": "S45",
                            "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                            "display": "Orthopaedic Surgery"
                          }
                        ]
                      }
                    ],
                    "serviceType": [
                      {
                        "coding": [
                          {
                            "code": "S45B",
                            "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                            "display": "S45B - Fracture Clinic"
                          }
                        ]
                      }
                    ],
                    "patientInstruction": "We will call you at the scheduled time. Please keep your phone nearby and ensure voicemail is enabled.",
                    "participant": [
                      {
                        "required": "required",
                        "status": "needs-action",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/nhi-id",
                            "value": "ZXP7823"
                          },
                          "display": "Carey Carrington"
                        }
                      },
                      {
                        "type": [
                          {
                            "coding": [
                              {
                                "code": "CON",
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                "display": "consultant"
                              }
                            ]
                          }
                        ],
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                            "value": "99ZZZX"
                          },
                          "display": "Dr Dotty McStuffins"
                        }
                      },
                      {
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "reference": "#DHOClinicLocation"
                        }
                      }
                    ],
                    "contained": [
                      {
                        "resourceType": "Location",
                        "id": "DHOClinicLocation",
                        "meta": {
                          "profile": [
                            "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                          ]
                        },
                        "identifier": [
                          {
                            "value": "4211-K01"
                          }
                        ],
                        "name": "Dunedin Hospital Outpatients, Clinic K01",
                        "partOf": {
                          "type": "Location",
                          "identifier": {
                            "value": "4211",
                            "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                          },
                          "display": "Dunedin Hospital"
                        },
                        "address": {
                          "use": "work",
                          "type": "physical",
                          "line": [
                            "350 Cumberland Street",
                            "Dunedin Central"
                          ],
                          "city": "Dunedin",
                          "postalCode": "9016",
                          "country": "New Zealand"
                        }
                      }
                    ],
                    "start": "2025-09-17T02:30:35Z",
                    "end": "2025-09-17T02:50:35Z"
                  }
                },
                "Appointment-DHOAppointmentUnstructuredExample-create": {
                  "value": {
                    "resourceType": "Appointment",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "lastUpdated": "2025-11-11T02:29:24.844Z",
                      "versionId": "3",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointment"
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                    },
                    "extension": [
                      {
                        "url": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentMethod",
                        "valueCodeableConcept": {
                          "coding": [
                            {
                              "code": "in-person",
                              "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-appointment-modality-cs",
                              "display": "In person"
                            }
                          ]
                        }
                      }
                    ],
                    "identifier": [
                      {
                        "value": "#fbdb8d66-1390-22c7-89a6-a9a75d65d3e6"
                      }
                    ],
                    "status": "booked",
                    "description": "Physiotherapy Appointment",
                    "serviceCategory": [
                      {
                        "coding": [
                          {
                            "code": "A01",
                            "system": "http://nzhts.digital.health.nz/fhir/CodeSystem/nc-health-specialty-codes",
                            "display": "Allied Health and other"
                          }
                        ]
                      }
                    ],
                    "serviceType": [
                      {
                        "coding": [
                          {
                            "code": "A01B",
                            "system": "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/dho-health-speciality-cs",
                            "display": "A01B - Physiotherapy"
                          }
                        ]
                      }
                    ],
                    "participant": [
                      {
                        "required": "required",
                        "status": "needs-action",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/nhi-id",
                            "value": "ZXP7823"
                          },
                          "display": "Carey Carrington"
                        }
                      },
                      {
                        "type": [
                          {
                            "coding": [
                              {
                                "code": "CON",
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                                "display": "consultant"
                              }
                            ]
                          }
                        ],
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "identifier": {
                            "use": "official",
                            "system": "https://standards.digital.health.nz/ns/hpi-person-id",
                            "value": "99ZZZX"
                          },
                          "display": "Dr Dotty McStuffins"
                        }
                      },
                      {
                        "required": "required",
                        "status": "accepted",
                        "actor": {
                          "reference": "#DHOClinicLocation"
                        }
                      }
                    ],
                    "contained": [
                      {
                        "resourceType": "Location",
                        "id": "DHOClinicLocation",
                        "meta": {
                          "profile": [
                            "http://hl7.org.nz/fhir/StructureDefinition/NzLocation"
                          ]
                        },
                        "identifier": [
                          {
                            "value": "4211-K01"
                          }
                        ],
                        "name": "Dunedin Hospital Outpatients, Clinic K01",
                        "partOf": {
                          "type": "Location",
                          "identifier": {
                            "value": "4211",
                            "system": "https://standards.digital.health.nz/ns/nzhis-facility-id"
                          },
                          "display": "Dunedin Hospital"
                        },
                        "address": {
                          "use": "work",
                          "type": "physical",
                          "line": [
                            "350 Cumberland Street",
                            "Dunedin Central"
                          ],
                          "city": "Dunedin",
                          "postalCode": "9016",
                          "country": "New Zealand"
                        }
                      }
                    ],
                    "start": "2025-09-03T02:30:35Z",
                    "end": "2025-09-03T03:30:35Z"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/Appointment.c"
            ]
          }
        ]
      }
    },
    "/AppointmentResponse": {
      "post": {
        "summary": "Create AppointmentResponse",
        "description": "Create AppointmentResponse",
        "tags": [
          "AppointmentResponse"
        ],
        "operationId": "createAppointmentResponse",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Successful create operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "AppointmentResponse"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              },
                              "minItems": 1
                            }
                          },
                          "required": [
                            "source",
                            "tag"
                          ]
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment response concern that are defined by business processes and/ or used to refer to it when a direct URL reference to the resource itself is not appropriate.",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "appointment": {
                          "description": "Appointment that this response is replying to.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "participantType": {
                          "type": "array",
                          "items": {
                            "description": "Role of participant in the appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "minItems": 1,
                          "maxItems": 1
                        },
                        "participantStatus": {
                          "type": "string",
                          "enum": [
                            "accepted",
                            "declined",
                            "tentative",
                            "needs-action"
                          ],
                          "description": "Participation status of the participant. When the status is declined or tentative if the start/end times are different to the appointment, then these times should be interpreted as a requested time change. When the status is accepted, the times can either be the time of the appointment (as a confirmation of the time) or can be empty."
                        }
                      },
                      "required": [
                        "resourceType",
                        "appointment",
                        "participantStatus",
                        "participantType"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentResponse"
                    }
                  ]
                },
                "examples": {
                  "AppointmentResponse-DHOAppointmentResponseExample": {
                    "value": {
                      "resourceType": "AppointmentResponse",
                      "id": "DHOAppointmentResponseExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "2",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentResponse"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "appointment": {
                        "identifier": {
                          "system": "urn:orion:pas:appointment:patient-appointment:code",
                          "value": "77350"
                        }
                      },
                      "participantType": [
                        {
                          "coding": [
                            {
                              "code": "SBJ",
                              "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                              "display": "Subject"
                            }
                          ]
                        }
                      ],
                      "participantStatus": "accepted"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful create operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful create operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful create operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful create operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "requestBody": {
          "description": "AppointmentResponse to create",
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "resourceType": {
                        "type": "string",
                        "enum": [
                          "AppointmentResponse"
                        ]
                      },
                      "id": {
                        "type": "string",
                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                        "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                      },
                      "meta": {
                        "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                        "type": "object",
                        "properties": {
                          "versionId": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                          },
                          "lastUpdated": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                            "description": "When the resource last changed &ndash; e.g. when the version changed."
                          },
                          "source": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                          },
                          "profile": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                            }
                          },
                          "security": {
                            "type": "array",
                            "items": {
                              "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "tag": {
                            "type": "array",
                            "items": {
                              "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            },
                            "minItems": 1
                          }
                        },
                        "required": [
                          "source",
                          "tag"
                        ]
                      },
                      "implicitRules": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                      },
                      "language": {
                        "type": "string",
                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                        "description": "The base language in which the resource is written."
                      },
                      "text": {
                        "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                        "type": "object",
                        "properties": {
                          "status": {
                            "type": "string",
                            "enum": [
                              "generated",
                              "extensions",
                              "additional",
                              "empty"
                            ],
                            "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                          },
                          "div": {
                            "type": "string",
                            "description": "The actual narrative content, a stripped down version of XHTML."
                          }
                        },
                        "required": [
                          "status",
                          "div"
                        ]
                      },
                      "contained": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "resourceType": {
                              "type": "string",
                              "enum": [
                                "Account",
                                "ActivityDefinition",
                                "AdverseEvent",
                                "AllergyIntolerance",
                                "Appointment",
                                "AppointmentResponse",
                                "AuditEvent",
                                "Basic",
                                "Binary",
                                "BiologicallyDerivedProduct",
                                "BodyStructure",
                                "Bundle",
                                "CapabilityStatement",
                                "CarePlan",
                                "CareTeam",
                                "CatalogEntry",
                                "ChargeItem",
                                "ChargeItemDefinition",
                                "Claim",
                                "ClaimResponse",
                                "ClinicalImpression",
                                "CodeSystem",
                                "Communication",
                                "CommunicationRequest",
                                "CompartmentDefinition",
                                "Composition",
                                "ConceptMap",
                                "Condition",
                                "Consent",
                                "Contract",
                                "Coverage",
                                "CoverageEligibilityRequest",
                                "CoverageEligibilityResponse",
                                "DetectedIssue",
                                "Device",
                                "DeviceDefinition",
                                "DeviceMetric",
                                "DeviceRequest",
                                "DeviceUseStatement",
                                "DiagnosticReport",
                                "DocumentManifest",
                                "DocumentReference",
                                "DomainResource",
                                "EffectEvidenceSynthesis",
                                "Encounter",
                                "Endpoint",
                                "EnrollmentRequest",
                                "EnrollmentResponse",
                                "EpisodeOfCare",
                                "EventDefinition",
                                "Evidence",
                                "EvidenceVariable",
                                "ExampleScenario",
                                "ExplanationOfBenefit",
                                "FamilyMemberHistory",
                                "Flag",
                                "Goal",
                                "GraphDefinition",
                                "Group",
                                "GuidanceResponse",
                                "HealthcareService",
                                "ImagingStudy",
                                "Immunization",
                                "ImmunizationEvaluation",
                                "ImmunizationRecommendation",
                                "ImplementationGuide",
                                "InsurancePlan",
                                "Invoice",
                                "Library",
                                "Linkage",
                                "List",
                                "Location",
                                "Measure",
                                "MeasureReport",
                                "Media",
                                "Medication",
                                "MedicationAdministration",
                                "MedicationDispense",
                                "MedicationKnowledge",
                                "MedicationRequest",
                                "MedicationStatement",
                                "MedicinalProduct",
                                "MedicinalProductAuthorization",
                                "MedicinalProductContraindication",
                                "MedicinalProductIndication",
                                "MedicinalProductIngredient",
                                "MedicinalProductInteraction",
                                "MedicinalProductManufactured",
                                "MedicinalProductPackaged",
                                "MedicinalProductPharmaceutical",
                                "MedicinalProductUndesirableEffect",
                                "MessageDefinition",
                                "MessageHeader",
                                "MolecularSequence",
                                "NamingSystem",
                                "NutritionOrder",
                                "Observation",
                                "ObservationDefinition",
                                "OperationDefinition",
                                "OperationOutcome",
                                "Organization",
                                "OrganizationAffiliation",
                                "Parameters",
                                "Patient",
                                "PaymentNotice",
                                "PaymentReconciliation",
                                "Person",
                                "PlanDefinition",
                                "Practitioner",
                                "PractitionerRole",
                                "Procedure",
                                "Provenance",
                                "Questionnaire",
                                "QuestionnaireResponse",
                                "RelatedPerson",
                                "RequestGroup",
                                "ResearchDefinition",
                                "ResearchElementDefinition",
                                "ResearchStudy",
                                "ResearchSubject",
                                "Resource",
                                "RiskAssessment",
                                "RiskEvidenceSynthesis",
                                "Schedule",
                                "SearchParameter",
                                "ServiceRequest",
                                "Slot",
                                "Specimen",
                                "SpecimenDefinition",
                                "StructureDefinition",
                                "StructureMap",
                                "Subscription",
                                "Substance",
                                "SubstanceNucleicAcid",
                                "SubstancePolymer",
                                "SubstanceProtein",
                                "SubstanceReferenceInformation",
                                "SubstanceSourceMaterial",
                                "SubstanceSpecification",
                                "SupplyDelivery",
                                "SupplyRequest",
                                "Task",
                                "TerminologyCapabilities",
                                "TestReport",
                                "TestScript",
                                "ValueSet",
                                "VerificationResult",
                                "VisionPrescription"
                              ]
                            },
                            "id": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                            },
                            "meta": {
                              "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                              "type": "object",
                              "properties": {
                                "versionId": {
                                  "type": "string",
                                  "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                  "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                },
                                "lastUpdated": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                  "description": "When the resource last changed &ndash; e.g. when the version changed."
                                },
                                "source": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                },
                                "profile": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                  }
                                },
                                "security": {
                                  "type": "array",
                                  "items": {
                                    "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "tag": {
                                  "type": "array",
                                  "items": {
                                    "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                }
                              }
                            },
                            "implicitRules": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                            },
                            "language": {
                              "type": "string",
                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                              "description": "The base language in which the resource is written."
                            }
                          },
                          "required": [
                            "resourceType"
                          ],
                          "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                        }
                      },
                      "extension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "modifierExtension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "identifier": {
                        "type": "array",
                        "items": {
                          "description": "This records identifiers associated with this appointment response concern that are defined by business processes and/ or used to refer to it when a direct URL reference to the resource itself is not appropriate.",
                          "type": "object",
                          "properties": {
                            "use": {
                              "type": "string",
                              "enum": [
                                "usual",
                                "official",
                                "temp",
                                "secondary",
                                "old"
                              ],
                              "description": "The purpose of this identifier."
                            },
                            "type": {
                              "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                            },
                            "value": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                            },
                            "period": {
                              "description": "Time period during which identifier is/was valid for use.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            },
                            "assigner": {
                              "description": "Organization that issued/manages the identifier.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            }
                          }
                        }
                      },
                      "appointment": {
                        "description": "Appointment that this response is replying to.",
                        "type": "object",
                        "properties": {
                          "reference": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                          },
                          "type": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                          },
                          "identifier": {
                            "type": "object",
                            "additionalProperties": true,
                            "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                          },
                          "display": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                          }
                        }
                      },
                      "participantType": {
                        "type": "array",
                        "items": {
                          "description": "Role of participant in the appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "minItems": 1,
                        "maxItems": 1
                      },
                      "participantStatus": {
                        "type": "string",
                        "enum": [
                          "accepted",
                          "declined",
                          "tentative",
                          "needs-action"
                        ],
                        "description": "Participation status of the participant. When the status is declined or tentative if the start/end times are different to the appointment, then these times should be interpreted as a requested time change. When the status is accepted, the times can either be the time of the appointment (as a confirmation of the time) or can be empty."
                      }
                    },
                    "required": [
                      "resourceType",
                      "appointment",
                      "participantStatus",
                      "participantType"
                    ],
                    "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentResponse"
                  }
                ]
              },
              "examples": {
                "AppointmentResponse-DHOAppointmentResponseExample-create": {
                  "value": {
                    "resourceType": "AppointmentResponse",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "lastUpdated": "2025-11-11T02:29:24.844Z",
                      "versionId": "2",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentResponse"
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                    },
                    "appointment": {
                      "identifier": {
                        "system": "urn:orion:pas:appointment:patient-appointment:code",
                        "value": "77350"
                      }
                    },
                    "participantType": [
                      {
                        "coding": [
                          {
                            "code": "SBJ",
                            "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                            "display": "Subject"
                          }
                        ]
                      }
                    ],
                    "participantStatus": "accepted"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/AppointmentResponse.c"
            ]
          }
        ]
      }
    },
    "/AppointmentResponse/{rid}": {
      "put": {
        "summary": "Update AppointmentResponse",
        "description": "Update AppointmentResponse",
        "tags": [
          "AppointmentResponse"
        ],
        "operationId": "updateAppointmentResponse",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "description": "Resource id",
            "name": "rid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful update operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "AppointmentResponse"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              },
                              "minItems": 1
                            }
                          },
                          "required": [
                            "source",
                            "tag"
                          ]
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "This records identifiers associated with this appointment response concern that are defined by business processes and/ or used to refer to it when a direct URL reference to the resource itself is not appropriate.",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "appointment": {
                          "description": "Appointment that this response is replying to.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "participantType": {
                          "type": "array",
                          "items": {
                            "description": "Role of participant in the appointment.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "minItems": 1,
                          "maxItems": 1
                        },
                        "participantStatus": {
                          "type": "string",
                          "enum": [
                            "accepted",
                            "declined",
                            "tentative",
                            "needs-action"
                          ],
                          "description": "Participation status of the participant. When the status is declined or tentative if the start/end times are different to the appointment, then these times should be interpreted as a requested time change. When the status is accepted, the times can either be the time of the appointment (as a confirmation of the time) or can be empty."
                        }
                      },
                      "required": [
                        "resourceType",
                        "appointment",
                        "participantStatus",
                        "participantType"
                      ],
                      "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentResponse"
                    }
                  ]
                },
                "examples": {
                  "AppointmentResponse-DHOAppointmentResponseExample": {
                    "value": {
                      "resourceType": "AppointmentResponse",
                      "id": "DHOAppointmentResponseExample",
                      "meta": {
                        "tag": [
                          {
                            "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                            "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                          }
                        ],
                        "lastUpdated": "2025-11-11T02:29:24.844Z",
                        "versionId": "2",
                        "profile": [
                          "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentResponse"
                        ],
                        "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                      },
                      "appointment": {
                        "identifier": {
                          "system": "urn:orion:pas:appointment:patient-appointment:code",
                          "value": "77350"
                        }
                      },
                      "participantType": [
                        {
                          "coding": [
                            {
                              "code": "SBJ",
                              "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                              "display": "Subject"
                            }
                          ]
                        }
                      ],
                      "participantStatus": "accepted"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Unsuccessful update operation - 400",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unsuccessful update operation - 401",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Unsuccessful update operation - 403",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Unsuccessful update operation - 500",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "resourceType": {
                      "type": "string",
                      "enum": [
                        "OperationOutcome"
                      ]
                    },
                    "id": {
                      "type": "string",
                      "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                      "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                    },
                    "meta": {
                      "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                      "type": "object",
                      "properties": {
                        "versionId": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                        },
                        "lastUpdated": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                          "description": "When the resource last changed &ndash; e.g. when the version changed."
                        },
                        "source": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                        },
                        "profile": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                          }
                        },
                        "security": {
                          "type": "array",
                          "items": {
                            "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        },
                        "tag": {
                          "type": "array",
                          "items": {
                            "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                            "type": "object",
                            "properties": {
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The identification of the code system that defines the meaning of the symbol in the code."
                              },
                              "version": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                              },
                              "code": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A representation of the meaning of the code in the system, following the rules of the system."
                              },
                              "userSelected": {
                                "type": "boolean",
                                "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                              }
                            }
                          }
                        }
                      }
                    },
                    "implicitRules": {
                      "type": "string",
                      "pattern": "\\S*",
                      "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                    },
                    "language": {
                      "type": "string",
                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                      "description": "The base language in which the resource is written."
                    },
                    "text": {
                      "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "string",
                          "enum": [
                            "generated",
                            "extensions",
                            "additional",
                            "empty"
                          ],
                          "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                        },
                        "div": {
                          "type": "string",
                          "description": "The actual narrative content, a stripped down version of XHTML."
                        }
                      },
                      "required": [
                        "status",
                        "div"
                      ]
                    },
                    "contained": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "resourceType": {
                            "type": "string",
                            "enum": [
                              "Account",
                              "ActivityDefinition",
                              "AdverseEvent",
                              "AllergyIntolerance",
                              "Appointment",
                              "AppointmentResponse",
                              "AuditEvent",
                              "Basic",
                              "Binary",
                              "BiologicallyDerivedProduct",
                              "BodyStructure",
                              "Bundle",
                              "CapabilityStatement",
                              "CarePlan",
                              "CareTeam",
                              "CatalogEntry",
                              "ChargeItem",
                              "ChargeItemDefinition",
                              "Claim",
                              "ClaimResponse",
                              "ClinicalImpression",
                              "CodeSystem",
                              "Communication",
                              "CommunicationRequest",
                              "CompartmentDefinition",
                              "Composition",
                              "ConceptMap",
                              "Condition",
                              "Consent",
                              "Contract",
                              "Coverage",
                              "CoverageEligibilityRequest",
                              "CoverageEligibilityResponse",
                              "DetectedIssue",
                              "Device",
                              "DeviceDefinition",
                              "DeviceMetric",
                              "DeviceRequest",
                              "DeviceUseStatement",
                              "DiagnosticReport",
                              "DocumentManifest",
                              "DocumentReference",
                              "DomainResource",
                              "EffectEvidenceSynthesis",
                              "Encounter",
                              "Endpoint",
                              "EnrollmentRequest",
                              "EnrollmentResponse",
                              "EpisodeOfCare",
                              "EventDefinition",
                              "Evidence",
                              "EvidenceVariable",
                              "ExampleScenario",
                              "ExplanationOfBenefit",
                              "FamilyMemberHistory",
                              "Flag",
                              "Goal",
                              "GraphDefinition",
                              "Group",
                              "GuidanceResponse",
                              "HealthcareService",
                              "ImagingStudy",
                              "Immunization",
                              "ImmunizationEvaluation",
                              "ImmunizationRecommendation",
                              "ImplementationGuide",
                              "InsurancePlan",
                              "Invoice",
                              "Library",
                              "Linkage",
                              "List",
                              "Location",
                              "Measure",
                              "MeasureReport",
                              "Media",
                              "Medication",
                              "MedicationAdministration",
                              "MedicationDispense",
                              "MedicationKnowledge",
                              "MedicationRequest",
                              "MedicationStatement",
                              "MedicinalProduct",
                              "MedicinalProductAuthorization",
                              "MedicinalProductContraindication",
                              "MedicinalProductIndication",
                              "MedicinalProductIngredient",
                              "MedicinalProductInteraction",
                              "MedicinalProductManufactured",
                              "MedicinalProductPackaged",
                              "MedicinalProductPharmaceutical",
                              "MedicinalProductUndesirableEffect",
                              "MessageDefinition",
                              "MessageHeader",
                              "MolecularSequence",
                              "NamingSystem",
                              "NutritionOrder",
                              "Observation",
                              "ObservationDefinition",
                              "OperationDefinition",
                              "OperationOutcome",
                              "Organization",
                              "OrganizationAffiliation",
                              "Parameters",
                              "Patient",
                              "PaymentNotice",
                              "PaymentReconciliation",
                              "Person",
                              "PlanDefinition",
                              "Practitioner",
                              "PractitionerRole",
                              "Procedure",
                              "Provenance",
                              "Questionnaire",
                              "QuestionnaireResponse",
                              "RelatedPerson",
                              "RequestGroup",
                              "ResearchDefinition",
                              "ResearchElementDefinition",
                              "ResearchStudy",
                              "ResearchSubject",
                              "Resource",
                              "RiskAssessment",
                              "RiskEvidenceSynthesis",
                              "Schedule",
                              "SearchParameter",
                              "ServiceRequest",
                              "Slot",
                              "Specimen",
                              "SpecimenDefinition",
                              "StructureDefinition",
                              "StructureMap",
                              "Subscription",
                              "Substance",
                              "SubstanceNucleicAcid",
                              "SubstancePolymer",
                              "SubstanceProtein",
                              "SubstanceReferenceInformation",
                              "SubstanceSourceMaterial",
                              "SubstanceSpecification",
                              "SupplyDelivery",
                              "SupplyRequest",
                              "Task",
                              "TerminologyCapabilities",
                              "TestReport",
                              "TestScript",
                              "ValueSet",
                              "VerificationResult",
                              "VisionPrescription"
                            ]
                          },
                          "id": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                          },
                          "meta": {
                            "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                            "type": "object",
                            "properties": {
                              "versionId": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                              },
                              "lastUpdated": {
                                "type": "string",
                                "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                "description": "When the resource last changed &ndash; e.g. when the version changed."
                              },
                              "source": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                              },
                              "profile": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                }
                              },
                              "security": {
                                "type": "array",
                                "items": {
                                  "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "tag": {
                                "type": "array",
                                "items": {
                                  "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              }
                            }
                          },
                          "implicitRules": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                          },
                          "language": {
                            "type": "string",
                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                            "description": "The base language in which the resource is written."
                          }
                        },
                        "required": [
                          "resourceType"
                        ],
                        "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                      }
                    },
                    "extension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "modifierExtension": {
                      "type": "array",
                      "items": {
                        "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                        "type": "object",
                        "additionalProperties": true
                      }
                    },
                    "issue": {
                      "type": "array",
                      "items": {
                        "description": "An error, warning, or information message that results from a system action.",
                        "type": "object",
                        "properties": {
                          "modifierExtension": {
                            "type": "array",
                            "items": {
                              "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                              "type": "object",
                              "additionalProperties": true
                            }
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "fatal",
                              "error",
                              "warning",
                              "information"
                            ],
                            "description": "Indicates whether the issue indicates a variation from successful processing."
                          },
                          "code": {
                            "type": "string",
                            "enum": [
                              "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"
                            ],
                            "description": "Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element."
                          },
                          "details": {
                            "description": "Additional details about the error. This may be a text description of the error or a system code that identifies the error.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          },
                          "diagnostics": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Additional diagnostic information about the issue."
                          },
                          "location": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. \n\nFor resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.  For HTTP errors, will be \"http.\" + the parameter name."
                            }
                          },
                          "expression": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A [simple subset of FHIRPath](fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised."
                            }
                          }
                        },
                        "required": [
                          "severity",
                          "code"
                        ]
                      },
                      "minItems": 1
                    }
                  },
                  "required": [
                    "resourceType",
                    "issue"
                  ]
                }
              }
            }
          }
        },
        "requestBody": {
          "description": "AppointmentResponse to create",
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "resourceType": {
                        "type": "string",
                        "enum": [
                          "AppointmentResponse"
                        ]
                      },
                      "id": {
                        "type": "string",
                        "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                        "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                      },
                      "meta": {
                        "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                        "type": "object",
                        "properties": {
                          "versionId": {
                            "type": "string",
                            "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                            "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                          },
                          "lastUpdated": {
                            "type": "string",
                            "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                            "description": "When the resource last changed &ndash; e.g. when the version changed."
                          },
                          "source": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                          },
                          "profile": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                            }
                          },
                          "security": {
                            "type": "array",
                            "items": {
                              "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            }
                          },
                          "tag": {
                            "type": "array",
                            "items": {
                              "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                              "type": "object",
                              "properties": {
                                "system": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                },
                                "version": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                },
                                "code": {
                                  "type": "string",
                                  "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                  "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                },
                                "userSelected": {
                                  "type": "boolean",
                                  "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                }
                              }
                            },
                            "minItems": 1
                          }
                        },
                        "required": [
                          "source",
                          "tag"
                        ]
                      },
                      "implicitRules": {
                        "type": "string",
                        "pattern": "\\S*",
                        "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                      },
                      "language": {
                        "type": "string",
                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                        "description": "The base language in which the resource is written."
                      },
                      "text": {
                        "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                        "type": "object",
                        "properties": {
                          "status": {
                            "type": "string",
                            "enum": [
                              "generated",
                              "extensions",
                              "additional",
                              "empty"
                            ],
                            "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                          },
                          "div": {
                            "type": "string",
                            "description": "The actual narrative content, a stripped down version of XHTML."
                          }
                        },
                        "required": [
                          "status",
                          "div"
                        ]
                      },
                      "contained": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "resourceType": {
                              "type": "string",
                              "enum": [
                                "Account",
                                "ActivityDefinition",
                                "AdverseEvent",
                                "AllergyIntolerance",
                                "Appointment",
                                "AppointmentResponse",
                                "AuditEvent",
                                "Basic",
                                "Binary",
                                "BiologicallyDerivedProduct",
                                "BodyStructure",
                                "Bundle",
                                "CapabilityStatement",
                                "CarePlan",
                                "CareTeam",
                                "CatalogEntry",
                                "ChargeItem",
                                "ChargeItemDefinition",
                                "Claim",
                                "ClaimResponse",
                                "ClinicalImpression",
                                "CodeSystem",
                                "Communication",
                                "CommunicationRequest",
                                "CompartmentDefinition",
                                "Composition",
                                "ConceptMap",
                                "Condition",
                                "Consent",
                                "Contract",
                                "Coverage",
                                "CoverageEligibilityRequest",
                                "CoverageEligibilityResponse",
                                "DetectedIssue",
                                "Device",
                                "DeviceDefinition",
                                "DeviceMetric",
                                "DeviceRequest",
                                "DeviceUseStatement",
                                "DiagnosticReport",
                                "DocumentManifest",
                                "DocumentReference",
                                "DomainResource",
                                "EffectEvidenceSynthesis",
                                "Encounter",
                                "Endpoint",
                                "EnrollmentRequest",
                                "EnrollmentResponse",
                                "EpisodeOfCare",
                                "EventDefinition",
                                "Evidence",
                                "EvidenceVariable",
                                "ExampleScenario",
                                "ExplanationOfBenefit",
                                "FamilyMemberHistory",
                                "Flag",
                                "Goal",
                                "GraphDefinition",
                                "Group",
                                "GuidanceResponse",
                                "HealthcareService",
                                "ImagingStudy",
                                "Immunization",
                                "ImmunizationEvaluation",
                                "ImmunizationRecommendation",
                                "ImplementationGuide",
                                "InsurancePlan",
                                "Invoice",
                                "Library",
                                "Linkage",
                                "List",
                                "Location",
                                "Measure",
                                "MeasureReport",
                                "Media",
                                "Medication",
                                "MedicationAdministration",
                                "MedicationDispense",
                                "MedicationKnowledge",
                                "MedicationRequest",
                                "MedicationStatement",
                                "MedicinalProduct",
                                "MedicinalProductAuthorization",
                                "MedicinalProductContraindication",
                                "MedicinalProductIndication",
                                "MedicinalProductIngredient",
                                "MedicinalProductInteraction",
                                "MedicinalProductManufactured",
                                "MedicinalProductPackaged",
                                "MedicinalProductPharmaceutical",
                                "MedicinalProductUndesirableEffect",
                                "MessageDefinition",
                                "MessageHeader",
                                "MolecularSequence",
                                "NamingSystem",
                                "NutritionOrder",
                                "Observation",
                                "ObservationDefinition",
                                "OperationDefinition",
                                "OperationOutcome",
                                "Organization",
                                "OrganizationAffiliation",
                                "Parameters",
                                "Patient",
                                "PaymentNotice",
                                "PaymentReconciliation",
                                "Person",
                                "PlanDefinition",
                                "Practitioner",
                                "PractitionerRole",
                                "Procedure",
                                "Provenance",
                                "Questionnaire",
                                "QuestionnaireResponse",
                                "RelatedPerson",
                                "RequestGroup",
                                "ResearchDefinition",
                                "ResearchElementDefinition",
                                "ResearchStudy",
                                "ResearchSubject",
                                "Resource",
                                "RiskAssessment",
                                "RiskEvidenceSynthesis",
                                "Schedule",
                                "SearchParameter",
                                "ServiceRequest",
                                "Slot",
                                "Specimen",
                                "SpecimenDefinition",
                                "StructureDefinition",
                                "StructureMap",
                                "Subscription",
                                "Substance",
                                "SubstanceNucleicAcid",
                                "SubstancePolymer",
                                "SubstanceProtein",
                                "SubstanceReferenceInformation",
                                "SubstanceSourceMaterial",
                                "SubstanceSpecification",
                                "SupplyDelivery",
                                "SupplyRequest",
                                "Task",
                                "TerminologyCapabilities",
                                "TestReport",
                                "TestScript",
                                "ValueSet",
                                "VerificationResult",
                                "VisionPrescription"
                              ]
                            },
                            "id": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                            },
                            "meta": {
                              "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                              "type": "object",
                              "properties": {
                                "versionId": {
                                  "type": "string",
                                  "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                  "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                },
                                "lastUpdated": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                  "description": "When the resource last changed &ndash; e.g. when the version changed."
                                },
                                "source": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                },
                                "profile": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                  }
                                },
                                "security": {
                                  "type": "array",
                                  "items": {
                                    "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "tag": {
                                  "type": "array",
                                  "items": {
                                    "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                }
                              }
                            },
                            "implicitRules": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                            },
                            "language": {
                              "type": "string",
                              "pattern": "[^\\s]+(\\s[^\\s]+)*",
                              "description": "The base language in which the resource is written."
                            }
                          },
                          "required": [
                            "resourceType"
                          ],
                          "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                        }
                      },
                      "extension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "modifierExtension": {
                        "type": "array",
                        "items": {
                          "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                          "type": "object",
                          "additionalProperties": true
                        }
                      },
                      "identifier": {
                        "type": "array",
                        "items": {
                          "description": "This records identifiers associated with this appointment response concern that are defined by business processes and/ or used to refer to it when a direct URL reference to the resource itself is not appropriate.",
                          "type": "object",
                          "properties": {
                            "use": {
                              "type": "string",
                              "enum": [
                                "usual",
                                "official",
                                "temp",
                                "secondary",
                                "old"
                              ],
                              "description": "The purpose of this identifier."
                            },
                            "type": {
                              "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                              "type": "object",
                              "properties": {
                                "coding": {
                                  "type": "array",
                                  "items": {
                                    "description": "A reference to a code defined by a terminology system.",
                                    "type": "object",
                                    "properties": {
                                      "system": {
                                        "type": "string",
                                        "pattern": "\\S*",
                                        "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                      },
                                      "version": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                      },
                                      "code": {
                                        "type": "string",
                                        "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                        "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                      },
                                      "display": {
                                        "type": "string",
                                        "pattern": "[ \\r\\n\\t\\S]+",
                                        "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                      },
                                      "userSelected": {
                                        "type": "boolean",
                                        "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                      }
                                    }
                                  }
                                },
                                "text": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                }
                              }
                            },
                            "system": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                            },
                            "value": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                            },
                            "period": {
                              "description": "Time period during which identifier is/was valid for use.",
                              "type": "object",
                              "properties": {
                                "start": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The start of the period. The boundary is inclusive."
                                },
                                "end": {
                                  "type": "string",
                                  "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                  "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                }
                              }
                            },
                            "assigner": {
                              "description": "Organization that issued/manages the identifier.",
                              "type": "object",
                              "properties": {
                                "reference": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                },
                                "type": {
                                  "type": "string",
                                  "pattern": "\\S*",
                                  "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                },
                                "identifier": {
                                  "type": "object",
                                  "additionalProperties": true,
                                  "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                },
                                "display": {
                                  "type": "string",
                                  "pattern": "[ \\r\\n\\t\\S]+",
                                  "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                }
                              }
                            }
                          }
                        }
                      },
                      "appointment": {
                        "description": "Appointment that this response is replying to.",
                        "type": "object",
                        "properties": {
                          "reference": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                          },
                          "type": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                          },
                          "identifier": {
                            "type": "object",
                            "additionalProperties": true,
                            "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                          },
                          "display": {
                            "type": "string",
                            "pattern": "[ \\r\\n\\t\\S]+",
                            "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                          }
                        }
                      },
                      "participantType": {
                        "type": "array",
                        "items": {
                          "description": "Role of participant in the appointment.",
                          "type": "object",
                          "properties": {
                            "coding": {
                              "type": "array",
                              "items": {
                                "description": "A reference to a code defined by a terminology system.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "text": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                            }
                          }
                        },
                        "minItems": 1,
                        "maxItems": 1
                      },
                      "participantStatus": {
                        "type": "string",
                        "enum": [
                          "accepted",
                          "declined",
                          "tentative",
                          "needs-action"
                        ],
                        "description": "Participation status of the participant. When the status is declined or tentative if the start/end times are different to the appointment, then these times should be interpreted as a requested time change. When the status is accepted, the times can either be the time of the appointment (as a confirmation of the time) or can be empty."
                      }
                    },
                    "required": [
                      "resourceType",
                      "appointment",
                      "participantStatus",
                      "participantType"
                    ],
                    "description": "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentResponse"
                  }
                ]
              },
              "examples": {
                "AppointmentResponse-DHOAppointmentResponseExample": {
                  "value": {
                    "resourceType": "AppointmentResponse",
                    "id": "DHOAppointmentResponseExample",
                    "meta": {
                      "tag": [
                        {
                          "system": "https://hub.services.digital.health.nz/ns/correlation-id",
                          "code": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                        }
                      ],
                      "lastUpdated": "2025-11-11T02:29:24.844Z",
                      "versionId": "2",
                      "profile": [
                        "https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/DHOAppointmentResponse"
                      ],
                      "source": "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D"
                    },
                    "appointment": {
                      "identifier": {
                        "system": "urn:orion:pas:appointment:patient-appointment:code",
                        "value": "77350"
                      }
                    },
                    "participantType": [
                      {
                        "coding": [
                          {
                            "code": "SBJ",
                            "system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
                            "display": "Subject"
                          }
                        ]
                      }
                    ],
                    "participantStatus": "accepted"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "smartOnFhir": [
              "system/AppointmentResponse.u"
            ]
          }
        ]
      }
    },
    "/CarePlan/{rid}": {
      "get": {
        "summary": "Read CarePlan",
        "description": "Read CarePlan",
        "tags": [
          "CarePlan"
        ],
        "operationId": "readCarePlan",
        "parameters": [
          {
            "name": "X-Correlation-Id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "A string representing the Correlation ID for the current request. This ID is used to correlate logs and other data across services."
            }
          },
          {
            "name": "Request-Context",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "format": "base64",
              "description": "A base64 encoded JSON object that represents the request context for the current request. See https://github.com/tewhatuora/schemas/blob/main/Request-Context.json for schema"
            }
          },
          {
            "description": "Resource id",
            "name": "rid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful read operation",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "resourceType": {
                          "type": "string",
                          "enum": [
                            "CarePlan"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                          "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                        },
                        "meta": {
                          "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                          "type": "object",
                          "properties": {
                            "versionId": {
                              "type": "string",
                              "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                              "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                            },
                            "lastUpdated": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                              "description": "When the resource last changed &ndash; e.g. when the version changed."
                            },
                            "source": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                            },
                            "profile": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                              }
                            },
                            "security": {
                              "type": "array",
                              "items": {
                                "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            },
                            "tag": {
                              "type": "array",
                              "items": {
                                "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                "type": "object",
                                "properties": {
                                  "system": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                  },
                                  "version": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                  },
                                  "code": {
                                    "type": "string",
                                    "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                    "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                  },
                                  "userSelected": {
                                    "type": "boolean",
                                    "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "implicitRules": {
                          "type": "string",
                          "pattern": "\\S*",
                          "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                        },
                        "language": {
                          "type": "string",
                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                          "description": "The base language in which the resource is written."
                        },
                        "text": {
                          "description": "A human&ndash;readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.",
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "generated",
                                "extensions",
                                "additional",
                                "empty"
                              ],
                              "description": "The status of the narrative &ndash; whether it's entirely generated (from just the defined data or the extensions too), or whether a human authored it and it may contain additional data."
                            },
                            "div": {
                              "type": "string",
                              "description": "The actual narrative content, a stripped down version of XHTML."
                            }
                          },
                          "required": [
                            "status",
                            "div"
                          ]
                        },
                        "contained": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "resourceType": {
                                "type": "string",
                                "enum": [
                                  "Account",
                                  "ActivityDefinition",
                                  "AdverseEvent",
                                  "AllergyIntolerance",
                                  "Appointment",
                                  "AppointmentResponse",
                                  "AuditEvent",
                                  "Basic",
                                  "Binary",
                                  "BiologicallyDerivedProduct",
                                  "BodyStructure",
                                  "Bundle",
                                  "CapabilityStatement",
                                  "CarePlan",
                                  "CareTeam",
                                  "CatalogEntry",
                                  "ChargeItem",
                                  "ChargeItemDefinition",
                                  "Claim",
                                  "ClaimResponse",
                                  "ClinicalImpression",
                                  "CodeSystem",
                                  "Communication",
                                  "CommunicationRequest",
                                  "CompartmentDefinition",
                                  "Composition",
                                  "ConceptMap",
                                  "Condition",
                                  "Consent",
                                  "Contract",
                                  "Coverage",
                                  "CoverageEligibilityRequest",
                                  "CoverageEligibilityResponse",
                                  "DetectedIssue",
                                  "Device",
                                  "DeviceDefinition",
                                  "DeviceMetric",
                                  "DeviceRequest",
                                  "DeviceUseStatement",
                                  "DiagnosticReport",
                                  "DocumentManifest",
                                  "DocumentReference",
                                  "DomainResource",
                                  "EffectEvidenceSynthesis",
                                  "Encounter",
                                  "Endpoint",
                                  "EnrollmentRequest",
                                  "EnrollmentResponse",
                                  "EpisodeOfCare",
                                  "EventDefinition",
                                  "Evidence",
                                  "EvidenceVariable",
                                  "ExampleScenario",
                                  "ExplanationOfBenefit",
                                  "FamilyMemberHistory",
                                  "Flag",
                                  "Goal",
                                  "GraphDefinition",
                                  "Group",
                                  "GuidanceResponse",
                                  "HealthcareService",
                                  "ImagingStudy",
                                  "Immunization",
                                  "ImmunizationEvaluation",
                                  "ImmunizationRecommendation",
                                  "ImplementationGuide",
                                  "InsurancePlan",
                                  "Invoice",
                                  "Library",
                                  "Linkage",
                                  "List",
                                  "Location",
                                  "Measure",
                                  "MeasureReport",
                                  "Media",
                                  "Medication",
                                  "MedicationAdministration",
                                  "MedicationDispense",
                                  "MedicationKnowledge",
                                  "MedicationRequest",
                                  "MedicationStatement",
                                  "MedicinalProduct",
                                  "MedicinalProductAuthorization",
                                  "MedicinalProductContraindication",
                                  "MedicinalProductIndication",
                                  "MedicinalProductIngredient",
                                  "MedicinalProductInteraction",
                                  "MedicinalProductManufactured",
                                  "MedicinalProductPackaged",
                                  "MedicinalProductPharmaceutical",
                                  "MedicinalProductUndesirableEffect",
                                  "MessageDefinition",
                                  "MessageHeader",
                                  "MolecularSequence",
                                  "NamingSystem",
                                  "NutritionOrder",
                                  "Observation",
                                  "ObservationDefinition",
                                  "OperationDefinition",
                                  "OperationOutcome",
                                  "Organization",
                                  "OrganizationAffiliation",
                                  "Parameters",
                                  "Patient",
                                  "PaymentNotice",
                                  "PaymentReconciliation",
                                  "Person",
                                  "PlanDefinition",
                                  "Practitioner",
                                  "PractitionerRole",
                                  "Procedure",
                                  "Provenance",
                                  "Questionnaire",
                                  "QuestionnaireResponse",
                                  "RelatedPerson",
                                  "RequestGroup",
                                  "ResearchDefinition",
                                  "ResearchElementDefinition",
                                  "ResearchStudy",
                                  "ResearchSubject",
                                  "Resource",
                                  "RiskAssessment",
                                  "RiskEvidenceSynthesis",
                                  "Schedule",
                                  "SearchParameter",
                                  "ServiceRequest",
                                  "Slot",
                                  "Specimen",
                                  "SpecimenDefinition",
                                  "StructureDefinition",
                                  "StructureMap",
                                  "Subscription",
                                  "Substance",
                                  "SubstanceNucleicAcid",
                                  "SubstancePolymer",
                                  "SubstanceProtein",
                                  "SubstanceReferenceInformation",
                                  "SubstanceSourceMaterial",
                                  "SubstanceSpecification",
                                  "SupplyDelivery",
                                  "SupplyRequest",
                                  "Task",
                                  "TerminologyCapabilities",
                                  "TestReport",
                                  "TestScript",
                                  "ValueSet",
                                  "VerificationResult",
                                  "VisionPrescription"
                                ]
                              },
                              "id": {
                                "type": "string",
                                "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                "description": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."
                              },
                              "meta": {
                                "description": "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.",
                                "type": "object",
                                "properties": {
                                  "versionId": {
                                    "type": "string",
                                    "pattern": "[A-Za-z0-9\\-\\.]{1,64}",
                                    "description": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted."
                                  },
                                  "lastUpdated": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))",
                                    "description": "When the resource last changed &ndash; e.g. when the version changed."
                                  },
                                  "source": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc."
                                  },
                                  "profile": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition&ndash;definitions.html#StructureDefinition.url)."
                                    }
                                  },
                                  "security": {
                                    "type": "array",
                                    "items": {
                                      "description": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "tag": {
                                    "type": "array",
                                    "items": {
                                      "description": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  }
                                }
                              },
                              "implicitRules": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."
                              },
                              "language": {
                                "type": "string",
                                "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                "description": "The base language in which the resource is written."
                              }
                            },
                            "required": [
                              "resourceType"
                            ],
                            "description": "These resources do not have an independent existence apart from the resource that contains them &ndash; they cannot be identified independently, and nor can they have their own independent transaction scope."
                          }
                        },
                        "extension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance  applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "modifierExtension": {
                          "type": "array",
                          "items": {
                            "description": "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                            "type": "object",
                            "additionalProperties": true
                          }
                        },
                        "identifier": {
                          "type": "array",
                          "items": {
                            "description": "Business identifiers assigned to this care plan by the performer or other systems which remain constant as the resource is updated and propagates from server to server.",
                            "type": "object",
                            "properties": {
                              "use": {
                                "type": "string",
                                "enum": [
                                  "usual",
                                  "official",
                                  "temp",
                                  "secondary",
                                  "old"
                                ],
                                "description": "The purpose of this identifier."
                              },
                              "type": {
                                "description": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
                                "type": "object",
                                "properties": {
                                  "coding": {
                                    "type": "array",
                                    "items": {
                                      "description": "A reference to a code defined by a terminology system.",
                                      "type": "object",
                                      "properties": {
                                        "system": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                        },
                                        "version": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                        },
                                        "code": {
                                          "type": "string",
                                          "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                          "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                        },
                                        "userSelected": {
                                          "type": "boolean",
                                          "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                        }
                                      }
                                    }
                                  },
                                  "text": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                  }
                                }
                              },
                              "system": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "Establishes the namespace for the value &ndash; that is, a URL that describes a set values that are unique."
                              },
                              "value": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "The portion of the identifier typically relevant to the user and which is unique within the context of the system."
                              },
                              "period": {
                                "description": "Time period during which identifier is/was valid for use.",
                                "type": "object",
                                "properties": {
                                  "start": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The start of the period. The boundary is inclusive."
                                  },
                                  "end": {
                                    "type": "string",
                                    "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                    "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                                  }
                                }
                              },
                              "assigner": {
                                "description": "Organization that issued/manages the identifier.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "instantiatesCanonical": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "The URL pointing to a FHIR&ndash;defined protocol, guideline, questionnaire or other definition that is adhered to in whole or in part by this CarePlan."
                          }
                        },
                        "instantiatesUri": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "\\S*",
                            "description": "The URL pointing to an externally maintained protocol, guideline, questionnaire or other definition that is adhered to in whole or in part by this CarePlan."
                          }
                        },
                        "basedOn": {
                          "type": "array",
                          "items": {
                            "description": "A care plan that is fulfilled in whole or in part by this care plan.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "replaces": {
                          "type": "array",
                          "items": {
                            "description": "Completed or terminated care plan whose function is taken by this new care plan.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "partOf": {
                          "type": "array",
                          "items": {
                            "description": "A larger care plan of which this particular care plan is a component or step.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "draft",
                            "active",
                            "on-hold",
                            "revoked",
                            "completed",
                            "entered-in-error",
                            "unknown"
                          ],
                          "description": "Indicates whether the plan is currently being acted upon, represents future intentions or is now a historical record."
                        },
                        "intent": {
                          "type": "string",
                          "enum": [
                            "proposal",
                            "plan",
                            "order",
                            "option"
                          ],
                          "description": "Indicates the level of authority/intentionality associated with the care plan and where the care plan fits into the workflow chain."
                        },
                        "category": {
                          "type": "array",
                          "items": {
                            "description": "Identifies what \"kind\" of plan this is to support differentiation between multiple co&ndash;existing plans; e.g. \"Home health\", \"psychiatric\", \"asthma\", \"disease management\", \"wellness plan\", etc.",
                            "type": "object",
                            "properties": {
                              "coding": {
                                "type": "array",
                                "items": {
                                  "description": "A reference to a code defined by a terminology system.",
                                  "type": "object",
                                  "properties": {
                                    "system": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                    },
                                    "version": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                    },
                                    "code": {
                                      "type": "string",
                                      "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                      "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                    },
                                    "userSelected": {
                                      "type": "boolean",
                                      "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                    }
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                              }
                            }
                          }
                        },
                        "title": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "Human&ndash;friendly name for the care plan."
                        },
                        "description": {
                          "type": "string",
                          "pattern": "[ \\r\\n\\t\\S]+",
                          "description": "A description of the scope and nature of the plan."
                        },
                        "subject": {
                          "description": "Identifies the patient or group whose intended care is described by the plan.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "encounter": {
                          "description": "The Encounter during which this CarePlan was created or to which the creation of this record is tightly associated.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "period": {
                          "description": "Indicates when the plan did (or is intended to) come into effect and end.",
                          "type": "object",
                          "properties": {
                            "start": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The start of the period. The boundary is inclusive."
                            },
                            "end": {
                              "type": "string",
                              "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                              "description": "The end of the period. If the end of the period is missing, it means no end was known or planned at the time the instance was created. The start may be in the past, and the end date in the future, which means that period is expected/planned to end at that time."
                            }
                          }
                        },
                        "created": {
                          "type": "string",
                          "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                          "description": "Represents when this particular CarePlan record was created in the system, which is often a system&ndash;generated date."
                        },
                        "author": {
                          "description": "When populated, the author is responsible for the care plan.  The care plan is attributed to the author.",
                          "type": "object",
                          "properties": {
                            "reference": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                            },
                            "type": {
                              "type": "string",
                              "pattern": "\\S*",
                              "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                            },
                            "identifier": {
                              "type": "object",
                              "additionalProperties": true,
                              "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                            },
                            "display": {
                              "type": "string",
                              "pattern": "[ \\r\\n\\t\\S]+",
                              "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                            }
                          }
                        },
                        "contributor": {
                          "type": "array",
                          "items": {
                            "description": "Identifies the individual(s) or organization who provided the contents of the care plan.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "careTeam": {
                          "type": "array",
                          "items": {
                            "description": "Identifies all people and organizations who are expected to be involved in the care envisioned by this plan.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "addresses": {
                          "type": "array",
                          "items": {
                            "description": "Identifies the conditions/problems/concerns/diagnoses/etc. whose management and/or mitigation are handled by this plan.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "supportingInfo": {
                          "type": "array",
                          "items": {
                            "description": "Identifies portions of the patient's record that specifically influenced the formation of the plan.  These might include comorbidities, recent procedures, limitations, recent assessments, etc.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "goal": {
                          "type": "array",
                          "items": {
                            "description": "Describes the intended objective(s) of carrying out the care plan.",
                            "type": "object",
                            "properties": {
                              "reference": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                              },
                              "type": {
                                "type": "string",
                                "pattern": "\\S*",
                                "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                              },
                              "identifier": {
                                "type": "object",
                                "additionalProperties": true,
                                "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                              },
                              "display": {
                                "type": "string",
                                "pattern": "[ \\r\\n\\t\\S]+",
                                "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                              }
                            }
                          }
                        },
                        "activity": {
                          "type": "array",
                          "items": {
                            "description": "Identifies a planned action to occur as part of the plan.  For example, a medication to be used, lab tests to perform, self&ndash;monitoring, education, etc.",
                            "type": "object",
                            "properties": {
                              "modifierExtension": {
                                "type": "array",
                                "items": {
                                  "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                  "type": "object",
                                  "additionalProperties": true
                                }
                              },
                              "outcomeCodeableConcept": {
                                "type": "array",
                                "items": {
                                  "description": "Identifies the outcome at the point when the status of the activity is assessed.  For example, the outcome of an education activity could be patient understands (or not).",
                                  "type": "object",
                                  "properties": {
                                    "coding": {
                                      "type": "array",
                                      "items": {
                                        "description": "A reference to a code defined by a terminology system.",
                                        "type": "object",
                                        "properties": {
                                          "system": {
                                            "type": "string",
                                            "pattern": "\\S*",
                                            "description": "The identification of the code system that defines the meaning of the symbol in the code."
                                          },
                                          "version": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "The version of the code system which was used when choosing this code. Note that a well&ndash;maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged."
                                          },
                                          "code": {
                                            "type": "string",
                                            "pattern": "[^\\s]+(\\s[^\\s]+)*",
                                            "description": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post&ndash;coordination)."
                                          },
                                          "display": {
                                            "type": "string",
                                            "pattern": "[ \\r\\n\\t\\S]+",
                                            "description": "A representation of the meaning of the code in the system, following the rules of the system."
                                          },
                                          "userSelected": {
                                            "type": "boolean",
                                            "description": "Indicates that this coding was chosen by a user directly &ndash; e.g. off a pick list of available items (codes or displays)."
                                          }
                                        }
                                      }
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user."
                                    }
                                  }
                                }
                              },
                              "outcomeReference": {
                                "type": "array",
                                "items": {
                                  "description": "Details of the outcome or action resulting from the activity.  The reference to an \"event\" resource, such as Procedure or Encounter or Observation, is the result/outcome of the activity itself.  The activity can be conveyed using CarePlan.activity.detail OR using the CarePlan.activity.reference (a reference to a &ldquo;request&rdquo; resource).",
                                  "type": "object",
                                  "properties": {
                                    "reference": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                    },
                                    "type": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                    },
                                    "identifier": {
                                      "type": "object",
                                      "additionalProperties": true,
                                      "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                    },
                                    "display": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                    }
                                  }
                                }
                              },
                              "progress": {
                                "type": "array",
                                "items": {
                                  "description": "Notes about the adherence/status/progress of the activity.",
                                  "type": "object",
                                  "properties": {
                                    "authorReference": {
                                      "description": "The individual responsible for making the annotation.",
                                      "type": "object",
                                      "properties": {
                                        "reference": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                        },
                                        "type": {
                                          "type": "string",
                                          "pattern": "\\S*",
                                          "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                        },
                                        "identifier": {
                                          "type": "object",
                                          "additionalProperties": true,
                                          "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                        },
                                        "display": {
                                          "type": "string",
                                          "pattern": "[ \\r\\n\\t\\S]+",
                                          "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                        }
                                      }
                                    },
                                    "authorString": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The individual responsible for making the annotation."
                                    },
                                    "time": {
                                      "type": "string",
                                      "pattern": "([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\\.[0-9]+)?(Z|(\\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)))?)?)?",
                                      "description": "Indicates when this particular annotation was made."
                                    },
                                    "text": {
                                      "type": "string",
                                      "pattern": "[ \\r\\n\\t\\S]+",
                                      "description": "The text of the annotation in markdown format."
                                    }
                                  },
                                  "required": [
                                    "text"
                                  ]
                                }
                              },
                              "reference": {
                                "description": "The details of the proposed activity represented in a specific resource.",
                                "type": "object",
                                "properties": {
                                  "reference": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources."
                                  },
                                  "type": {
                                    "type": "string",
                                    "pattern": "\\S*",
                                    "description": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources)."
                                  },
                                  "identifier": {
                                    "type": "object",
                                    "additionalProperties": true,
                                    "description": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference."
                                  },
                                  "display": {
                                    "type": "string",
                                    "pattern": "[ \\r\\n\\t\\S]+",
                                    "description": "Plain text narrative that identifies the resource in addition to the resource reference."
                                  }
                                }
                              },
                              "detail": {
                                "description": "A simple summary of a planned activity suitable for a general care plan system (e.g. form driven) that doesn't know about specific resources such as procedure etc.",
                                "type": "object",
                                "properties": {
                                  "modifierExtension": {
                                    "type": "array",
                                    "items": {
                                      "description": "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
                                      "type": "object",
                                      "additionalProperties": true
                                    }
                                  },
                                  "kind": {
                                    "type": "string",
                                    "enum": [
                                      "Appointment",
                                      "CommunicationRequest",
                                      "DeviceRequest",
                                      "MedicationRequest",
                                      "NutritionOrder",
                                      "Task",
                                      "ServiceRequest",
                                      "VisionPrescription"
                                    ],
                                    "description": "A description of the kind of resource the in&ndash;line definition of a care plan activity is representing.  The CarePlan.activity.detail is an in&ndash;line definition when a resource is not referenced using CarePlan.activity.reference.  For example, a MedicationRequest, a ServiceRequest, or a CommunicationRequest."
                                  },
                                  "instantiatesCanonical": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The URL pointing to a FHIR&ndash;defined protocol, guideline, questionnaire or other definition that is adhered to in whole or in part by this CarePlan activity."
                                    }
                                  },
                                  "instantiatesUri": {
                                    "type": "array",
                                    "items": {
                                      "type": "string",
                                      "pattern": "\\S*",
                                      "description": "The URL pointing to an externally maintained protocol, guideline, questionnaire or other definition that is adhered to in whole or in part by this CarePlan activity."
                                    }
                                  },
                                  "code": {
                                    "description": "Detailed description of the type of planned activity; e.g. what lab test, what procedure, what kind of encounter.",
                                    "type": "object",
                                    "properties": {
                                      "coding": {
                                        "type": "array",
                                        "items": {
                                          "description": "A reference to a code defined by a terminology system.",
                                          "type": "object",
                                          "properties": {
                                            "system": {
        