Snapshot 3: Connectathon 32 Base

This is Snapshot #3 for FHIR R5, released to support Connectathon 32. For a full list of available versions, see the Directory of published versions.

Example Bundle/bundle-response (Turtle)

FHIR Infrastructure Work GroupMaturity Level: N/AStandards Status: InformativeCompartments: Not linked to any defined compartments

Raw Turtle (+ also see Turtle/RDF Format Specification)

Response for the example transaction

@prefix fhir: <http://hl7.org/fhir/> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

# - resource -------------------------------------------------------------------

[a fhir:Bundle;
  fhir:nodeRole fhir:treeRoot;
  fhir:Resource.id [ fhir:value "bundle-response"]; # 
  fhir:Resource.meta [
     fhir:Meta.lastUpdated [ fhir:value "2014-08-18T01:43:33Z"^^xsd:dateTime ]
  ]; #    this example bundle is a transaction response    ,    when the transaction response was constructed   
  fhir:Bundle.type [ fhir:value "transaction-response"]; # 
  fhir:Bundle.entry [
     fhir:index 0;
     fhir:Bundle.entry.fullUrl [ fhir:value "http://example.org/fhir/Patient/12423" ];
     fhir:Bundle.entry.resource <http://example.org/fhir/Patient/12423>; #    response for the simple create operation   ,    whether to return the result resource depends on client preference   
     fhir:Bundle.entry.response [
       fhir:Bundle.entry.response.status [ fhir:value "201 Created" ]; #    important responses from the server   
       fhir:Bundle.entry.response.location [ fhir:value "Patient/12423/_history/1" ];
       fhir:Bundle.entry.response.etag [ fhir:value "W/\"1\"" ];
       fhir:Bundle.entry.response.lastModified [ fhir:value "2014-08-18T01:43:33Z"^^xsd:dateTime ];
       fhir:Bundle.entry.response.outcome [
         a fhir:OperationOutcome;
         fhir:OperationOutcome.issue [
           fhir:index 0;
           fhir:OperationOutcome.issue.severity [ fhir:value "warning" ];
           fhir:OperationOutcome.issue.code [ fhir:value "not-found" ];
           fhir:OperationOutcome.issue.details [
             fhir:CodeableConcept.text [ fhir:value "The Managing organization was not known and was deleted" ]
           ];
           fhir:OperationOutcome.issue.expression [
             fhir:value "Patient.managingOrganization";
             fhir:index 0
           ]
         ]
       ]
     ] #    now, details about the action to take with the resource   
  ], [
     fhir:index 1;
     fhir:Bundle.entry.response [
       fhir:Bundle.entry.response.status [ fhir:value "200 OK" ] #    no action taken   
     ] #    response to the conditional create operation   ,    in this case, there was a match to the If-None-Exist header   
  ], [
     fhir:index 2;
     fhir:Bundle.entry.response [
       fhir:Bundle.entry.response.status [ fhir:value "200 OK" ];
       fhir:Bundle.entry.response.location [ fhir:value "Patient/123/_history/4" ];
       fhir:Bundle.entry.response.etag [ fhir:value "W/\"4\"" ]
     ] #    response to a simple update operation   ,    no return resource for this example, though in a \n      real transaction, all entries would have a resource or all would not \n      
  ], [
     fhir:index 3;
     fhir:Bundle.entry.response [
       fhir:Bundle.entry.response.status [ fhir:value "201 Created" ]; #    created a new resource for this one   
       fhir:Bundle.entry.response.location [ fhir:value "Patient/12424/_history/1" ];
       fhir:Bundle.entry.response.etag [ fhir:value "W/\"1\"" ]
     ] #    response to the conditional update operation   
  ], [
     fhir:index 4;
     fhir:Bundle.entry.response [
       fhir:Bundle.entry.response.status [ fhir:value "200 ok" ]; #    created a new resource for this one   
       fhir:Bundle.entry.response.location [ fhir:value "Patient/123a/_history/3" ];
       fhir:Bundle.entry.response.etag [ fhir:value "W/\"3\"" ]
     ] #    response to the 2nd conditional update operation   
  ], [
     fhir:index 5;
     fhir:Bundle.entry.response [
       fhir:Bundle.entry.response.status [ fhir:value "202 Accepted" ] #    successful deletion   
     ] #    response to the simple delete operation   
  ], [
     fhir:index 6;
     fhir:Bundle.entry.response [
       fhir:Bundle.entry.response.status [ fhir:value "DELETE" ] #    delete matching resource - but you can't find out what was deleted - an inherent limitation in a condition delete   
     ] #    response to the conditional delete operation   
  ], [
     fhir:index 7;
     fhir:Bundle.entry.fullUrl [ fhir:value "urn:uuid:7f9724ed-ef8d-4434-aacb-41869db83233" ];
     fhir:Bundle.entry.resource <urn:uuid:7f9724ed-ef8d-4434-aacb-41869db83233>; #    operation response   ,    etc.  
     fhir:Bundle.entry.response [
       fhir:Bundle.entry.response.status [ fhir:value "200 ok" ] #    POST to [base]\/ValueSet\/$lookup - invoking a lookup operation (see Terminology Service)   
     ]
  ], [
     fhir:index 8;
     fhir:Bundle.entry.fullUrl [ fhir:value "urn:uuid:e7bcef8e-5ef9-4d2b-87d5-b42b1eec9125" ];
     fhir:Bundle.entry.resource <urn:uuid:e7bcef8e-5ef9-4d2b-87d5-b42b1eec9125>; #    response to search   ,    etc.  
     fhir:Bundle.entry.response [
       fhir:Bundle.entry.response.status [ fhir:value "200 OK" ]
     ]
  ], [
     fhir:index 9;
     fhir:Bundle.entry.response [
       fhir:Bundle.entry.response.status [ fhir:value "304 Not Modified" ]
     ] #    response to conditional read - no changes 
  ]] . #    
    one entry for each entry in the transaction, in order, with a 
    response
    

<http://example.org/fhir/Patient/12423> a fhir:Patient;
  fhir:Resource.id [ fhir:value "12423"]; # 
  fhir:Resource.meta [
     fhir:Meta.versionId [ fhir:value "1" ];
     fhir:Meta.lastUpdated [ fhir:value "2014-08-18T01:43:31Z"^^xsd:dateTime ]
  ]; # 
  fhir:DomainResource.text [
     fhir:Narrative.status [ fhir:value "generated" ];
     fhir:Narrative.div "<div xmlns=\"http://www.w3.org/1999/xhtml\">Some narrative</div>"
  ]; # 
  fhir:Patient.active [ fhir:value "true"^^xsd:boolean]; # 
  fhir:Patient.name [
     fhir:index 0;
     fhir:HumanName.use [ fhir:value "official" ];
     fhir:HumanName.family [ fhir:value "Chalmers" ];
     fhir:HumanName.given [
       fhir:value "Peter";
       fhir:index 0
     ], [
       fhir:value "James";
       fhir:index 1
     ]
  ]; # 
  fhir:Patient.gender [ fhir:value "male"]; # 
  fhir:Patient.birthDate [ fhir:value "1974-12-25"^^xsd:date] . # 

<urn:uuid:7f9724ed-ef8d-4434-aacb-41869db83233> a fhir:Parameters;
  fhir:Parameters.parameter [
     fhir:index 0;
     fhir:Parameters.parameter.name [ fhir:value "name" ];
     fhir:Parameters.parameter.valueString [ fhir:value "LOINC" ]
  ] . # 

<urn:uuid:e7bcef8e-5ef9-4d2b-87d5-b42b1eec9125> a fhir:Bundle;
  fhir:Resource.id [ fhir:value "fb6ed6cb-324e-4588-87cd-0c92c68986ca"]; # 
  fhir:Bundle.type [ fhir:value "searchset"] . # 

# - ontology header ------------------------------------------------------------

[a owl:Ontology;
  owl:imports fhir:fhir.ttl] .

# -------------------------------------------------------------------------------------


Usage note: every effort has been made to ensure that the examples are correct and useful, but they are not a normative part of the specification.