Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Introduction


Excerpt

...

The Logica has adopted portions of the FHIR RESTful service specification for reading, writing and searching for clinical data. Details of the FHIR RESTful services specification can be found here: http://www.hl7.org/implement/standards/fhir/http.html


RESTful API 
Anchor
RESTful API
RESTful API

The following describes the RESTful services which are available for all supported FHIR resources. The basic CRUD operations (Create, Retrieve, Update, Delete) are supported as well as search. For details on supported query parameters, refer to the query capabilities links in the table above.

...

  • Content surrounded by [] is mandatory, and will be replaced the string literal identified. Possible insertion values:
    • base: The service root URL (e.g. http(s)://server{/path})
    • type: The name of a resource type (e.g. "patient", "observation")
    • id: The logical id of a resource
    • parameters: URL parameters as defined for the particular operation
  • Supported mime-types: application/json+fhir, application/json
  • Content surrounded by {} is optional 

Create Resource

Details of the FHIR RESTful services specification for creating a resource can be found here: http://www.hl7.org/implement/standards/fhir/http.html#create.

HTTP POST Command

POST [base]/[type] {?_format=[mime-type]}
Code Block
languagexml
themeEclipse
titleSample JSON Payload
collapsetrue
{
   "resourceType" : "Patient",
   "text" :
      {
         "status" : "generated",
         "div" : "<div><p>PT-ONE XTESTHIMSS</p></div>"
      },
   "identifier" :
      [
         {
            "use" : "usual",
            "label" : "IHC Hospital EMPI",
            "system" : "urn:oid:0.1.2.3.4.5.6.7",
            "value" : "549614826"
         }
      ],
   "name" :
      [
         {
            "use" : "official",
            "family" :
               [
                  "XTESTHIMSS"
               ],
            "given" :
               [
                  "PT-ONE"
               ]
         }
      ],
   "telecom" :
      [
         {
            "system" : "phone",
            "use" : "home"
         },
         {
            "system" : "phone",
            "use" : "mobile"
         }
      ],
   "gender" :
      {
         "coding" :
            [
               {
                  "system" : "http://hl7.org/fhir/v3/AdministrativeGender",
                  "code" : "F",
                  "display" : "Female"
               }
            ]
      },
   "birthDate" : "2010-12-16T00:00:00",
   "address" :
      [
         {
            "use" : "home"
         }
      ],
   "active" : true
}

Delete Resource

Details of the FHIR RESTful services specification for deleting a resource can be found here: http://www.hl7.org/implement/standards/fhir/http.html#delete.

HTTP DELETE Command

DELETE [base]/[type]/[id] {?_format=[mime-type]}
 


Update Resource

Details of the FHIR RESTful services specification for updating a resource can be found here: http://www.hl7.org/implement/standards/fhir/http.html#update.

Note: The HSPC The Logica platform does not currently support creation of a resource with a client defined ID. PUT can only be used to update an existing resource.

HTTP PUT Command

PUT [base]/[type]/[id] {?_format=[mime-type]}
Code Block
languagexml
themeEclipse
titleSample JSON Payload
collapsetrue
{
   "resourceType" : "Patient",
   "text" :
      {
         "status" : "generated",
         "div" : "<div><p>PT-ONE XTESTHIMSS</p></div>"
      },
   "identifier" :
      [
         {
            "use" : "usual",
            "label" : "IHC Hospital EMPI",
            "system" : "urn:oid:0.1.2.3.4.5.6.7",
            "value" : "549614826"
         }
      ],
   "name" :
      [
         {
            "use" : "official",
            "family" :
               [
                  "XTESTHIMSS"
               ],
            "given" :
               [
                  "PT-ONE"
               ]
         }
      ],
   "telecom" :
      [
         {
            "system" : "phone",
            "use" : "home"
         },
         {
            "system" : "phone",
            "use" : "mobile"
         }
      ],
   "gender" :
      {
         "coding" :
            [
               {
                  "system" : "http://hl7.org/fhir/v3/AdministrativeGender",
                  "code" : "F",
                  "display" : "Female"
               }
            ]
      },
   "birthDate" : "2010-12-16T00:00:00",
   "address" :
      [
         {
            "use" : "home"
         }
      ],
   "active" : true
}
 


Reading by Logical Identifier

Details of the FHIR RESTful services specification for reading a resource can be found here: http://www.hl7.org/implement/standards/fhir/http.html#read.

HTTP GET Command

GET [base]/[type]/[id] {?_format=[mime-type]}

Searching a Resource Type by Parameters

Details of the FHIR RESTful services specification for searching for a resource can be found here: http://www.hl7.org/implement/standards/fhir/http.html#search.

See individual resource documentation for more details about currently supported search parameters.

HTTP GET Command for Searching

GET [base]/[type]?[parameters] {&_format=[mime-type]}

General Query Parameters 
Anchor
GeneralQueryParameters
GeneralQueryParameters

Details of the FHIR RESTful services specification for sorting and paging result sets can be found here: http://www.hl7.org/implement/standards/fhir/search.html#sort.

...