HOSPITAL API

Hospital resources are a formally or informally recognized grouping of people or organizations formed for the purpose of achieving some form of collective action. Includes companies, institutions, corporations, departments, community groups.

This API uses FHIR format and standards to create a hospital with hospital specific data.

POST  https://deepsepsis.cohere-med.com/api/Organization
Request Body Syntax:
{
       "resourceType": "Organization",
       "active": true | false,
       "type": [
        {
           "coding": [
            {
               "system": "http://hl7.org/fhir/organization-type",
               "code": "Hospital",
               "display": [“string”]
            }
          ]
        }
      ],
       "Name": [“string”]
     }
Request Properties: 
Properties Type Description
resourceType
String
Required, Specifies the type of the resource which is “Organization” in this case.
active
Boolean
Required, Whether the organization’s record is still active and in use.
type
List []
Required, codeable concept.
coding
List []
Required, List of codes to identify the organization’s details.
system
String
Required, URL defining the FHIR standard systems.
display
String
Optional, name of the organization/Hospital.
name
String
Optional, name of the organization/Hospital.
Sample Request:
{
       "resourceType": "Organization",
       "meta": {
       },
       "active": true,
       "type": [
         {
           "coding": [
             {
               "system": "http://hl7.org/fhir/organization-type",
               "code": "Hospital",
               "display": "st marthas Hospital"
             }
           ]
         }
       ],
       "name": "st marthas Hospital"
     }
Response Properties: 
Properties Type Description
resourceType
String
The resource type that was created.
id
Identifier
Unique identifier or reference for the created resource, also known as Organization Reference ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
versionId
Identifier
Required, List of codes to identify the organization’s details.
lastUpdated
Time Instant
Time at which the resource was last updated/ created.
source
URI
An URI that identifies the source system of the resource. The source may identify another FHIR server, document, message, database, etc.
active
Boolean
The current status of the organisation’s use in the records.
type
List []
Codeable concept.
coding
List []
List of codes to identify the organisation’s details.
system
String
URL defining the FHIR standard systems.
code
String
Codes used to identify the organisation type.
display
String
Name of the organisation/hospital.
name
String
Name of the organisation/hospital
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource records have been fetched.
400
Unsuccessful Request, Invalid Organization id/parameter.
Sample Response:
Status: 201 Created
{
 "resourceType": "Organization",
 "id": "1303"
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-08-27T10:56:59.508+00:00"
 },
 "active": true,
 "type": [
   {
     "coding": [
       {
         "system": "http://hl7.org/fhir/organization-type",
         "code": "Hospital"
       }
     ]
   }
 ],
 "name": "st marthas Hospital"
}
Description: This API fetches hospital details based on the Organization identifier.
Request Syntax:
Request Properties:
Properties Type Description
Organization_id
Identifier
Organization_ID of an existing Organization.
Response Properties:
Properties Type Description
resourceType
String
The resource type that was created.
id
Identifier
Unique identifier or reference for the created resource, also known as Hospital Reference ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
versionId
Identifier
Required, List of codes to identify the organization’s details.
lastUpdated
Time Instant
Time at which the resource was last updated/ created.
source
URI
An URI that identifies the source system of the resource. The source may identify another FHIR server, document, message, database, etc.
active
Boolean
The current status of the organisation’s use in the records.
type
List []
Codeable concept.
coding
List []
List of codes to identify the organisation’s details.
system
String
URL defining the FHIR standard systems.
code
String
Codes used to identify the organisation type.
display
String
Name of the organisation/hospital.
name
String
Name of the organisation/hospital
Querying with specific parameters:

The GET method can also be used to search or query with specific parameters.

Example:

Request to fetch all hospitals.

Sample Request:

GET https://deepsepsis.cohere-med.com/api/Organization?type=Hospital

Sample Response:

Status: 200 OK

Fetches all the organization of type hospital

Example:

Request to get departments at a hospital.

Sample Request:

GET https://deepsepsis.cohere-med.com/api/Organization?partOf=1303&type=Department

Sample Response:

Status: 200 OK
Fetches all records of departments in an Organization of Organization ID 1303.
Search Parameters:
Name Type Description Example
identifier
token
Any identifier to the hospital/Organization.
https://deepsepsis.cohere-med.com/api/Patient?organization=1303
partof
reference
An organization of which this organization forms a part of.
https://deepsepsis.cohere-med.com/api/Organization?partOf=2301
type
token
A code for the type of Organization.
https://deepsepsis.cohere-med.com/api/Organization?type=Hospital`
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource records have been fetched.
400
Unsuccessful Request, Invalid Organization id/parameter.

Sample Request:

GET https://deepsepsis.cohere-med.com/api/Organization/1303

Sample Response:
Status: 200 OK
{
 "resourceType": "Organization",
 "id": "1303",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-08-27T10:47:40.716+00:00",
   "source": "#c2IfXn01bE44w5lQ"
 },
 "active": true,
 "type": [
   {
     "coding": [
       {
         "system": "http://hl7.org/fhir/organization-type",
         "code": "Hospital",
         "display": "st marthas Hospital"
       }
     ]
   }
 ],
 "name": "st marthas Hospital"
}

PUThttps://deepsepsis.cohere-med.com/api/Organization/{organization_id}

Description: This API updates the existing organization details based on the identifier
Request Syntax:

PUT https://deepsepsis.cohere-med.com/api/Organization/{organization_id}

{
‘’’
Updated Organization resource body
‘’’
}

Request Properties:
Properties Type Description
Organization_id
Identifier
Organization_ID of an existing Organization.

Sample Request:

*note: The request body must contain the created resource identifier information.

PUT https://deepsepsis.cohere-med.com/api/p/Organization/1303

Updated Json body.

 {
 "resourceType": "Organization",
 "id": "1303",
 "active": true,
 "type": [
   {
     "coding": [
       {
         "system":"http://hl7.org/fhir/organization-type",
         "code": "Hospital"
       }
     ]
   }
 ],
 "name":St marthas Hospital for Cancer Care"
}
Response Properties:
Properties Type Description
resourceType
String
The resource type that was created.
id
Identifier
Unique identifier or reference for the created resource, also known as Organization Reference ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
versionId
Identifier
Required, List of codes to identify the organization’s details.
lastUpdated
Time Instant
Time at which the resource was last updated/ created.
source
URI
An URI that identifies the source system of the resource. The source may identify another FHIR server, document, message, database, etc.
active
Boolean
The current status of the organisation’s use in the records.
type
List []
Codeable concept.
coding
List []
List of codes to identify the organisation’s details.
system
String
URL defining the FHIR standard systems.
code
String
Codes used to identify the organisation type.
display
String
Name of the organisation/hospital.
name
String
Name of the organisation/hospital
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource has been updated.
400
Unsuccessful Request, Invalid Request data.
Sample Response:
Status: 200 OK
{
 "resourceType": "Organization",
 "id": "1303",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-08-27T11:47:59.508+00:00"
 },
 "active": true,
 "type": [
   {
     "coding": [
       {
         "system": "http://hl7.org/fhir/organization-type",
         "code": "Hospital"
       }
     ]
   }
 ],
 "name":St marthas Hospital for Cancer Care"
}
DELETE https://deepsepsis.cohere-med.com/api/Organization/{id}
Description: This API deletes the Hospital and its details from the records.
Request Syntax:
DELETE https://deepsepsis.cohere-med.com/api/Organization/{organization_id}
Request Properties:
Properties Type Description
Organization_id
Identifier
Organization_ID of an existing Organization.
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource records have been fetched.
400
Unsuccessful Request, Invalid Request data.
Sample Request: DELETE https://deepsepsis.cohere-med.com/api/Organization/1303
Sample Response:
Status: 200 OK

Organization resources of ID 1303 are successfully deleted .

DEPARTMENT API

The Organization resources can be used to create various departments under an organization/hospital.
This API creates and manages departments in an existing organization/Hospital.

POST https://deepsepsis.cohere-med.com/api/Organization

Request Body Syntax:
{
       "resourceType": "Organization",
       "meta": {
       },
       "active": true|false,
       "type": [
         {
           "coding": [
             {
               "system": "http://hl7.org/fhir/organization-type",
               "code": "Department",
               "display": [“string”]
             }
           ]
         }
       ],
       "name": [“string”],
       "partOf": {
         "reference": "Organization/{Organization_id}"
       } }
Request Properties:
Properties Type Description
resourceType
String
Required, Specifies the type of the resource which is “Department”.
active
Boolean
equired, Whether the organization’s record is still active and in use.
coding
List []
List of codes to identify the Department details.
type[0].coding[0].system
String
List [Required, URL defining the FHIR standard systems.
type[0].coding[0].code
String
Required, Codes used to identify the organization type, in this case it specifies that it’s a department resource
type[0].code[0].display
String
Optional, name of the Department in the existing organization .
Name
String
Optional, name of the Department in the existing organization.
partOf
Reference
The organization of which this organization/Department forms a part
partOf.reference
String
Required, Hospital/ Organisation Identifier

Sample Request:

POST https://deepsepsis.cohere-med.com/api/Organization

{
       "resourceType": "Organization",
       "meta": {
       },
       "active": true,
       "type": [
         {
           "coding": [
             {
               "system": "http://hl7.org/fhir/organization-type",
               "code": "Department",
               "display": "Emergency Department"
             }
           ]
         }
       ],
       "name": "Emergency Department",
       "partOf": {
         "reference": "Organization/1303"
       }
   }
Response Properties:
Properties Type Description
resourceType
String
The resource type that was created.
id
Identifier
Unique identifier or reference for the created resource, also known as Hospital Reference ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
active
Boolean
The current status of the organisation’s use in the records.
coding
List []
List of codes to identify the organisation’s details.
type[0].coding[0].system
String
URL defining the FHIR standard systems.
type[0].coding[0].code
String
Codes used to identify the organisation type.
type[0].coding[0].display
String
Name of the department created
name
String
Name of the department created
partOf
Reference
The organization of which this organization/Department forms a part.
partOf.reference
String
Hospital/Organisation Identifier.
Error Codes:
Properties Description
200
Successful Request. Indicates that the Department resource has been created under the specified organization/Hospital.
400
Unsuccessful Request, Invalid Request body.
Sample Response:
Status: 200 OK
{
 "resourceType": "Organization",
 "id": "1404",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-01T05:19:36.222+00:00"
 },
 "active": true,
 "type": [
   {
     "coding": [
       {
         "system""http://hl7.org/fhir/organization-type",
         "code": "Department",
         "display": "Emergency Department"
       }
     ]
   }
 ],
 "name": "Emergency Department",
 "partOf": {
   "reference": "Organization/1303"
 }

re

GET https://deepsepsis.cohere-med.com/api/Organization/{id}

Description: This API fetches the department details in an organization based on the Department Identifier.
Request Syntax:

GET https://deepsepsis.cohere-med.com/api/Organization/{Department_id}

Request Properties:
Properties Type Description
Department_id
Identifier
Department_ID of an existing Department.
Response Properties:
Properties Type Description
resourceType
String
The resource type that was created.
id
Identifier
Unique identifier or reference for the created resource, also known as Hospital Reference ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
source
URI
An URI that identifies the source system of the resource. The source may identify another FHIR server, document, message, database, etc.
active
Boolean
The current status of the organisation’s use in the records.
coding
List []
List of codes to identify the organisation’s details.
type[0].coding[0].system
String
URL defining the FHIR standard systems.
type[0].coding[0].code
String
Codes used to identify the organisation type.
type[0].coding[0].display
String
Name of the department created
name
String
Name of the department created
partOf
Reference
The organization of which this organization/Department forms a part.
partOf.reference
String
Hospital/Organisation Identifier.
Querying with specific parameters:

The GET method can also be used to search or query with specific parameters.

Example:

To query/fetch all Intensive Care units.

Sample Request :

GET  https://deepsepsis.cohere-med.com/api/Organization?name=ICU 

Sample Response:

Status: 200 OK

This will fetch all records where the department name is ICU in an organization.

Example:

To query/fetch record of Emergency departments referenced under a specific organization.

Sample Request :

GET  https://deepsepsis.cohere-med.com/api/Organization?name=Emergency Department&_id=1303 

Sample Response:

Status: 200 OK
Fetches records where the department name is Emergency Department and Organization ID is 1303
Search Parameters:
Name Type Description Example
identifier
token
Any identifier to the hospital/Organization.
partof
reference
An organization of which this organization forms a part of.
type
token
A code for the type of Organization.
Error Codes:
Properties Description
200
Successful Request. Indicates that the Department resource records have been fetched.
400
Unsuccessful Request, Invalid Department identifier.

Sample Request:

GET https://deepsepsis.cohere-med.com/api/Organization/1404

Sample Response:
Status: 200 OK

 "resourceType": "Organization",
 "id": "1404",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-01T05:19:36.222+00:00",
   "source": "#jF5xFZu9LTQFjALN"
 },
 "active": true,
 "type": [
   {
     "coding": [
       {
         "system":"http://hl7.org/fhir/organization-type",
         "code": "Department",
         "display": "Emergency Department"
       }
     ]
   }
 ],
 "name": "Emergency Department",
 "partOf": {
   "reference": "Organization/1303"
 }
}

PUT https://deepsepsis.cohere-med.com/api/Organization/{id}

Description: This API updates and manages details of an existing Department.
Request Syntax:

PUT https://deepsepsis.cohere-med.com/api/Organization/{department_id}
{
‘’’
Updated Organization resource body
‘’’
}

Request Properties:
Properties Type Description
Department_id
Identifier
Department_ID of an existing Department.

Sample Request:

*note: The request body must contain the identifier of the originally created resource.

{
 "resourceType": "Organization",
 "id": "1404",
 "active": true,
 "type": [
   {
     "coding": [
       {
         "system":"http://hl7.org/fhir/organization-type",
         "code": "Department",
         "display": "ICU"
       }
     ]
   }
 ],
 "name": "ICU",
 "partOf": {
   "reference": "Organization/1303"
 }
}
Response Properties:
Properties Type Description
resourceType
String
The resource type that was created.
id
Identifier
Unique identifier or reference for the created resource, also known as Hospital Reference ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
active
Boolean
The current status of the organisation’s use in the records.
coding
List []
List of codes to identify the organisation’s details.
type[0].coding[0].system
String
URL defining the FHIR standard systems.
type[0].coding[0].code
String
Codes used to identify the organisation type.
type[0].coding[0].display
String
Name of the department created
name
String
Name of the department created
partOf
Reference
The organization of which this organization/Department forms a part.
partOf.reference
String
Hospital/Organisation Identifier.
Error Codes:
Properties Description
200
Successful Request. Indicates that the Department resource has been Updated.
400
Unsuccessful Request, Invalid Department identifier/Invalid Resource Identifier/ Wrong request body.
Sample Response:
Status: 200 OK
{
 "resourceType": "Organization",
 "id": "1404",
 "meta": {
   "versionId": "2",
   "lastUpdated": "2020-09-01T05:54:45.325+00:00",
   "source": "#jF5xFZu9LTQFjALN"
 },
 "active": true,
 "type": [
   {
     "coding": [
       {
         "system":"http://hl7.org/fhir/organization-type",
         "code": "Department",
         "display": "ICU"
       }
     ]
   }
 ],
 "name": "ICU",
 "partOf": {
   "reference": "Organization/1303"
 }
}

DELETE https://deepsepsis.cohere-med.com/api/Organization/{id}

Description: This API deletes the specified department from the organization/Hospital.
Request Syntax:

DELETE https://deepsepsis.cohere-med.com/api/Organization/{Department_id}

Request Properties:
Properties Type Description
Department_id
Identifier
Department_ID of an existing Department.
Error Codes:
Properties Description
200
Successful Request. Indicates that the specified Department resource has been deleted.
400
Unsuccessful Request, Invalid Department ID.

Sample Request:

DELETE https://deepsepsis.cohere-med.com/api/Organization/1404

Sample Response:
Status: 200 OK

Resource is successfully deleted.

BED API

This API creates and manages Beds in the existing departments of an Organization, it requires the Department Identifier in order to create and manage the resources.

POST https://deepsepsis.cohere-med.com/api/Location

Description: This API creates beds in a Department associated with an organization or a Hospital.
Request Body Syntax:
{
       "resourceType": "Location",
       "status": [“active”|”suspended”|”inactive”],
       "name":[‘string”],
       "type": [
        {
           "coding": [
            {
               "system": "http://hl7.org/fhir/location-physical-type",
               "code": "bed",
               "display": ["string"]
            }
          ]
        }
      ],
       "managingOrganization": {
         "reference": "Organization/{department_id}"
      }
     }
Request Properties:
Properties Type Description
resourceType
String
Required, Specifies the type of the resource.
status
String, Code
Required, Specifies the bed status. Options: “active” , “inactive”, “suspended”
coding
List []
List of codes to identify the Location details.
type[0].coding[0].system
String
Required, URL defining the FHIR standard systems.
type[0].coding[0].code
String
Required, Codes used to identify the physical location type, in this case it specifies that it’s a location of type bed.
type[0].code[0].display
String
Optional, name of the Bed in the specified Department.
Name
String
Optional, name of the Department in the existing organization.
managingOrganization
Reference (Location)
Department responsible for managing and upkeep.
managingOrganization.reference
String
Required, Reference to the managing Department. This is specified through the unique Department identifier.
Sample Request:
{
       "resourceType": "Location",
       "status": "active",
       "name": "Bed-ED-5",
       "type": [
         {
           "coding": [
             {
               "system": "http://hl7.org/fhir/location-physical-type",
               "code": "bed",
               "display": "Bed-ED-5"
             }
           ]
         }
       ],
       "managingOrganization": {
         "reference": "Organization/1404"
       }
     }
Response Properties:
Properties Type Description
resourceType
String
The resource type that was created.
id
Identifier
Unique identifier or reference for the created Bed resource, also known as Location Reference ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
The current status of the Bed/location.
coding
List []
List of codes to identify the Location details.
type[0].coding[0].system
String
Required, URL defining the FHIR standard systems.
type[0].coding[0].code
String
Required, Codes used to identify the physical location type, in this case it specifies that it’s a location of type bed.
type[0].coding[0].display
String
Optional, name of the Bed in the specified Department.
managingOrganization
Reference(Location)
Department responsible for managing and upkeep.
managingOrganization.reference
Reference
Reference to the managing Department. This is specified through the unique Department identifier.
Sample Response:
Status: 200 OK
{
 "resourceType": "Location",
 "id": "1452",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-01T10:44:51.245+00:00"
 },
 "status": "active",
 "name": "Bed-ED-5",
 "type": [
   {
     "coding": [
       {
         "system": "http://hl7.org/fhir/location-physical-type",
         "code": "bed",
         "display": "Bed-ED-5"
       }
     ]
   }
 ],
 "managingOrganization": {
   "reference": "Organization/1404"
 }
}
Error Codes:
Properties Description
200
Successful Request. Indicates that the Bed resource has been created under the specified Department.
400
Unsuccessful Request, Invalid Request data.

GET https://deepsepsis.cohere-med.com/api/Location/{ID}

Description: This API fetches the Bed details based on the location identifier.
Request Syntax:

GET https://deepsepsis.cohere-med.com/api/Location/{Location_ID}

Request Properties:
Properties Type Description
Location_id
Identifier
Location_ID of an existing location in a Department.
Response Properties:
Properties Type Description
resourceType
String
The resource type that was created.
id
Identifier
Unique identifier or reference for the created Bed resource, also known as location reference ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
The current status of the Bed/ location.
type
List []
Codeable concept.
coding
List []
List of codes to identify the location details.
type[0].coding[0].system
String
URL defining the FHIR standard systems.
type[0].coding[0].code
String
Codes used to identify the physical location type, in this case it specifies that it’s a location of type bed.
type[0].coding[0].display
String
Name of the Bed in the specified Department.
managingOrganization
Reference(Location)String
Department responsible for managing and upkeep.
managingOrganization.reference
Reference
Reference to the managing Department. This is specified through the unique Department identifier.

Sample Request:

GET https://deepsepsis.cohere-med.com/api/Location/1452

Sample Response:
Status: 200 OK
{
 "resourceType": "Location",
 "id": "1452",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-01T10:44:51.245+00:00",
   "source": "#Ra7OhKsePaYz0f2w"
 },
 "status": "active",
 "name": "Bed-ED-5",
 "type": [
   {
     "coding": [
       {
         "system": "http://hl7.org/fhir/location-physical-type",
         "code": "bed",
         "display": "Bed-ED-5"
       }
     ]
   }
 ],
 "managingOrganization": {
   "reference": "Organization/1303"
 }
}
Querying with specific parameters:

The GET method can also be used to search or query with specific parameters.

Example:

Example to query/fetch all active beds.

Sample Request :

GET  https://deepsepsis.cohere-med.com/api/Location?status=active

Sample Response:

Status: 200 OK
This will fetch all location records with active status.
Search Parameters:
Name Type Description Example
identifier
token
Any identifier to the hospital/Organization.

https://deepsepsis.cohere-med.com/api/Location?Location=1452

partof
reference
An organization of which this organization forms a part of.

https://deepsepsis.cohere-med.com/api/Location?partOf=2301

organization
reference
Searches for locations that are managed by the provided Organization.

https://deepsepsis.cohere-med.com/api/Location?managingOrganization=1303

status
token
Searches for locations with specific status

https://deepsepsis.cohere-med.com/api/Location?status=active

Error Codes:
Properties Description
200
Successful Request. Indicates that the Bed/ Location resource records have been fetched.
400
Unsuccessful Request, Invalid Location Reference Identifier.

PUT https://deepsepsis.cohere-med.com/api/Location/{ID}

Description: This API updates the existing location/Bed information.
Request Syntax:

PUT https://deepsepsis.cohere-med.com/api/Location/{Location_ID}
{
‘’’
Updated Organization resource body
‘’’
}

Request Properties:
Properties Type Description
Location_id
Identifier
Location_ID of an existing location in a Department.

Sample Request:

PUT https://deepsepsis.cohere-med.com/api/Location/1452

*note: The request body must contain the created resource identifier information.

{
"resourceType": "Location",
"id": "1452",
"status": "active",
"name": "Bed-ED-5001",
"type": [
  {
    "coding": [
      {
        "system": "http://hl7.org/fhir/location-physical-type",
        "code": "bed",
        "display": "Bed-ED-5001"
      }
    ]
  }
],
"managingOrganization": {
  "reference": "Organization/1404"
}
}
Response Properties:
Properties Type Description
resourceType
String
The resource type that was created.
id
Identifier
Unique identifier or reference for the created Bed resource, also known as Location Reference ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
The current status of the Bed/location.
coding
List []
List of codes to identify the Location details.
type[0].coding[0].system
String
Required, URL defining the FHIR standard systems.
type[0].coding[0].code
String
Required, Codes used to identify the physical location type, in this case it specifies that it’s a location of type bed.
type[0].coding[0].display
String
Optional, name of the Bed in the specified Department.
managingOrganization
Reference(Location)
Department responsible for managing and upkeep.
managingOrganization.reference
Reference
Reference to the managing Department. This is specified through the unique Department identifier.
Sample Response:
Status: 200 OK
{
 "resourceType": "Location",
 "id": "1452",
 "meta": {
   "versionId": "2",
   "lastUpdated": "2020-09-01T12:15:13.076+00:00",
   "source": "#Ra7OhKsePaYz0f2w"
 },
 "status": "active",
 "name": "Bed-ED-5001",
 "type": [
   {
     "coding": [
       {
         "system": "http://hl7.org/fhir/location-physical-type",
         "code": "bed",
         "display": "Bed-ED-5001"
       }
     ]
   }
 ],
 "managingOrganization": {
   "reference": "Organization/1404"
 }
}
Error Codes:
Properties Description
200
Successful Request. Indicates that the location resource has been updated.
400
Unsuccessful Request, Invalid Request data or Invalid Location Identifier .

DELETE https://deepsepsis.cohere-med.com/api/Location/{ID}

Description: This API deletes the specified Bed/ Location from a department.
Request Syntax:

DELETE https://deepsepsis.cohere-med.com/api/Location/{Location_ID}

Request Properties:
Properties Type Description
Location_id
Identifier
Location_ID of an existing location in a Department.
Error Codes:
Properties Description
200
Successful Request. Indicates that the specified Location/Bed resource has been deleted.
400
Unsuccessful Request, Invalid Location ID.

Sample Request:

DELETE https://deepsepsis.cohere-med.com/api/Location/1452

Sample Response:
Status: 200 OK

Resource is successfully deleted.

PATIENT API

Patient resources contain demographics and other administrative information about an individual receiving care or other health-related services.
This API creates and manages patient records in an Organization or a Hospital.

POST https://deepsepsis.cohere-med.com/api/Patient

Description: This API creates patient resources referenced under a hospital/ (an) organization.
Request Body Syntax:
{
       "resourceType": "Patient",
         "extension": [
        {
           "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
           "valueId": "race"
        },
        {
           "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
           "valueString": [“string”]
        }
      ],
       "identifier": [
        {
           "type": {
             "coding": [
              {
                 "id": "P_MRN",
                 "code": "MRN",
                 "display": [“string”]
              }
            ]
          },
           "value": [“alphanumeric”]
        }
      ],
       "active": [true | false],
       "gender": [male | female],
       "birthDate": [DOB in yyyy-mm-dd format],
       "managingOrganization": {
         "reference": "Organization/{organization_id}"
      }
     }
Request Properties:
Properties Type Description
resourceType
String
Required, Indicates the type of the resource which is “patient”.
extension
List []
An extension to the Patient resource to mention Race details.
extension[0].url
URL
Required, FHIR URL specifying the code definition.
extension[0].valueId
String
Required, Code to specify racial attribute.
extension[1].url
URL
Required, FHIR URL specifying the code definition.
extension[1].valueString
String
Optional, Specifies the racial status of the patient.
identifier
List []
List containing the patient details.
identifier[0].coding[0].id
Identifier
Required, Patient Identifier type.
identifier[0].coding[0].code
String
Required, Code for Patient identifier.
identifier[0].coding[0].display
String
Required, Name of the identifier
identifier[0].value
alphanumeric
Required, Unique Patient identifier.
Required, Unique Patient identifier.
active
Boolean
Required, Specifies if the patient is active in the organization’s record.
gender
String
Optional, Gender of the patient.
birthDate
Date
Optional, Date of Birth in the format yyyy-mm-dd.
managingOrganization
Reference(Organization)
Organization responsible for managing and upkeep.
managingOrganization.reference
Reference
Required, Reference to the managing organization/Hospital. This is specified through the unique organization /Hospital identifier.

Sample Request:

POST https://deepsepsis.cohere-med.com/fhir/Patient

{
       "resourceType": "Patient",
       "extension": [
         {
           "url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
           "valueId": "race"
         },
         {
           "url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
           "valueString": "WHITE"
         }
       ],
       "identifier": [
         {
           "type": {
             "coding": [
               {
                 "id": "P_MRN",
                 "code": "MRN",
                 "display": "MRN"
               }
             ]
           },
           "value": "123427272"
         }
       ],
       "active": true,
       "gender": "male",
       "birthDate": "1965-05-03",
       "managingOrganization": {
         "reference": "Organization/1303"
       }
     }
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “patient”.
id
Identifier
Unique identifier or reference for the created patient resource, also known as Patient ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
text.status
String
Status of the created patient resource.
text.div
String
Generated by FHIR server.
extension
List []
An extension to the Patient resource to mention Race details.
extension[0].url
URL
FHIR URL specifying the code definition.
extension[0].valueId
String
Code to specify racial attributes.
extension[1].url
URL
FHIR URL specifying the code definition.
extension[1].valueString
String
Specifies the racial status of the patient.
identifier
List []
List containing the patient details.
identifier[0].coding[0].id
identifier
Patient Identifier type.
identifier[0].coding[0].code
String
Code for Patient identifier.
identifier[0].coding[0].display
String
Name of the identifier
identifier[0].value
alphanumeric
Unique Patient identifier.
active
Boolean
Specifies if the patient is active in the organization’s record.
gender
String
Gender of the patient.
birthDate
Date
Date of Birth in the format yyyy-mm-dd.
managingOrganization
Reference(organization)
Organization responsible for managing and upkeep.
managingOrganization.reference
Reference
Reference to the managing organization/Hospital. This is specified through the unique organization /Hospital identifier.
Sample Response:
Status: 201 Created

 "resourceType": "Patient",
 "id": "1552",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-02T06:51:14.151+00:00"
 },
 "text": {
   "status": "generated",
   "div": "<div xmlns=\"http://www.w3.org/1999/xhtml\"><table class=\"hapiPropertyTable\"><tbody><tr><td>Identifier</td><td>123427272</td></tr><tr><td>Date of birth</td><td><span>03 May 1965</span></td></tr></tbody></table></div>"
 },
 "extension": [
   {
     "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
     "valueId": "race"
   },
   {
     "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
     "valueString": "WHITE"
   }
 ],
 "identifier": [
   {
     "type": {
       "coding": [
         {
           "id": "P_MRN",
           "code": "MRN",
           "display": "MRN"
         }
       ]
     },
     "value": "123427272"
   }
 ],
 "active": true,
 "gender": "male",
 "birthDate": "1965-05-03",
 "managingOrganization": {
   "reference": "Organization/1303"
 }
}
Error Codes:
Properties Description
201
Successful Request. Indicates that the specified Patient resource has been created.
400
Unsuccessful Request, Invalid Request data.

GET https://deepsepsis.cohere-med.com/api/Patient/{id}

Description: This API fetches the patient records for a specific patient based on the Unique Patient Identifier.
Request Syntax:

GET https://deepsepsis.cohere-med.com/api/Patient/{Patient_id}

Request Properties:
Properties Type Description
Patient_id
Identifier
Patient_ID of an existing patient resource.
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “patient”
id
Identifier
Unique identifier or reference for the created patient resource, also known as Patient ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
text.status
String
Status of the created patient resource.
text.div
String
Generated by FHIR server.
extension
List []
An extension to the Patient resource to mention Race details.
extension[0].url
URL
FHIR URL specifying the code definition.
extension[0].valueId
String
Code to specify racial attributes.
extension[1].url
URL
FHIR URL specifying the code definition.
extension[1].valueString
String
Specifies the racial status of the patient.
identifier
List []
List containing the patient details.
identifier[0].coding[0].id
identifier
Patient Identifier type.
identifier[0].coding[0].code
String
Code for Patient identifier.
identifier[0].coding[0].display
String
Name of the identifier
identifier[0].value
alphanumeric
Unique Patient identifier.
active
Boolean
Specifies if the patient is active in the organization’s record.
gender
String
Gender of the patient.
birthDate
Date
Date of Birth in the format yyyy-mm-dd.
managingOrganization
Reference(organization)
Organization responsible for managing and upkeep.
managingOrganization.reference
Reference
Reference to the managing organization/Hospital. This is specified through the unique organization /Hospital identifier.
Querying with specific parameters:

The GET method can also be used to search or query with specific parameters.

Example: To query/fetch all male patients.

Sample Request :

GET  https://deepsepsis.cohere-med.com/api/Patient?gender=male

Sample Response:

Status: 200 OK
This will fetch all location records with active status.
Search Parameters:
Name Type Description Example
active
token
Whether the patient’s record is active.
https://deepsepsis.cohere-med.com/api/Patient?active
gender
Token
Gender of the patient
https://deepsepsis.cohere-med.com/api/Patient?gender=’male’
organization
Reference
The organization that is the custodian of the patient record.
https://deepsepsis.cohere-med.com/api/Patient?organization=1303
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource records have been fetched.
400
Unsuccessful Request, Invalid Request data.

Sample Request:

GET https://deepsepsis.cohere-med.com/api/Patient/1552

Sample Response:
Status: 200 OK
 "resourceType": "Patient",
 "id": "1552",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-02T06:51:14.151+00:00",
   "source": "#ZK6DTzgJbIMu98ov"
 },
 "text": {
   "status": "generated",
   "div": ""<div xmlns=\"http://www.w3.org/1999/xhtml\"><table class=\"hapiPropertyTable\"><tbody><tr><td>Identifier</td><td>123427272</td></tr><tr><td>Date of birth</td><td><span>03 May 1965</span></td></tr></tbody></table></div>"
 },
 "extension": [
   {
     "url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
     "valueId": "race"
   },
   {
     "url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
     "valueString": "WHITE"
   }
 ],
 "identifier": [
   {
     "type": {
       "coding": [
         {
           "id": "P_MRN",
           "code": "MRN",
           "display": "MRN"
         }
       ]
     },
     "value": "123427272"
   }
 ],
 "active": true,
 "gender": "male",
 "birthDate": "1965-05-03",
 "managingOrganization": {
   "reference": "Organization/1303"
 }
}

PUT https://deepsepsis.cohere-med.com/api/Patient/{id}

Description: This API updates and manages the Patient resources.
Request Syntax:

PUT https://deepsepsis.cohere-med.com/api/Patient/{patient_id}
{

Updated Patient Resource

}

Request Properties:
Properties Type Description
Patient_id
Identifier
Patient_ID of an existing patient resource.

Sample Request:

PUT https://deepsepsis.cohere-med.com/api/Patient/1552

*note: The request body must contain the Patient Resource ID.


 "resourceType": "Patient",
 "id": "1552",
 "extension": [
   {
     "url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
     "valueId": "race"
   },
   {
     "url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
     "valueString": "WHITE"
   }
 ],
 "identifier": [
   {
     "type": {
       "coding": [
         {
           "id": "P_MRN",
           "code": "MRN",
           "display": "MRN"
         }
       ]
     },
     "value": "123427272"
   }
 ],
 "active": true,
 "gender": "female",
 "birthDate": "1965-05-03",
 "managingOrganization": {
   "reference": "Organization/1303"
 }
}
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “patient”.
id
Identifier
Unique identifier or reference for the created patient resource, also known as Patient ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
text.status
String
Status of the created patient resource.
text.div
String
Generated by FHIR server.
extension
List []
An extension to the Patient resource to mention Race details.
extension[0].url
URL
FHIR URL specifying the code definition.
extension[0].valueId
String
Code to specify racial attributes.
extension[1].url
URL
FHIR URL specifying the code definition.
extension[1].valueString
String
Specifies the racial status of the patient.
identifier
List []
List containing the patient details.
identifier[0].coding[0].id
identifier
Patient Identifier type.
identifier[0].coding[0].code
String
Code for Patient identifier.
identifier[0].coding[0].display
String
Name of the identifier
identifier[0].value
alphanumeric
Unique Patient identifier.
active
Boolean
Specifies if the patient is active in the organization’s record.
gender
String
Gender of the patient.
birthDate
Date
Date of Birth in the format yyyy-mm-dd.
managingOrganization
Reference(organization)
Organization responsible for managing and upkeep.
managingOrganization.reference
Reference
Reference to the managing organization/Hospital. This is specified through the unique organization /Hospital identifier.
Sample Response:
Status: 200 OK

 "resourceType": "Patient",
 "id": "1552",
 "meta": {
   "versionId": "2",
   "lastUpdated": "2020-09-02T08:04:38.684+00:00"
 },
 "text": {
   "status": "generated",
   "div": "

Identifier 123427272
Date of birth 03 May 1965
"  },  "extension": [    {      "url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",      "valueId": "race"    },    {      "url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",      "valueString": "WHITE"    }  ],  "identifier": [    {      "type": {        "coding": [          {            "id": "P_MRN",            "code": "MRN",            "display": "MRN"          }        ]      },      "value": "123427272"    }  ],  "active": true,  "gender": "female",  "birthDate": "1965-05-03",  "managingOrganization": {    "reference": "Organization/1303"  } }
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource has been updated.
400
Successful Request. Indicates that the Department resource has been Updated.

DELETE https://deepsepsis.cohere-med.com/api/Patient/{id}

Description: This API deletes the patient details for a specified patient based on the patient identifier.
Request Syntax:

DELETE https://deepsepsis.cohere-med.com/api/Patient/{Patient_id}

Request Properties:
Properties Type Description
Patient_id
Identifier
Patient_ID of an existing patient resource.
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource records have been fetched.
400
Unsuccessful Request, Invalid Request data.

Sample Request:

DELETE https://deepsepsis.cohere-med.com/api/Patient/1552

Sample Response:
Status: 200 OK

Resource is successfully deleted.

EPISODE OF CARE API

Episode of care resource is an association between a patient and an organization / healthcare provider(s) during which time encounters may occur. The managing organization assumes a level of responsibility for the patient during this time.
This API creates, manages Episode of Care for all existing patients referenced under  an organization/ (a) hospital.
POST https://deepsepsis.cohere-med.com/api/EpisodeOfCare
Description: This API creates an Episode of care resource for an existing patient in an organization.
Request Body Syntax:
POST https://deepsepsis.cohere-med.com/api/EpisodeOfCare
{
       "resourceType": "EpisodeOfCare",
       "status": [“active” | “inactive” | “suspended”],
       "patient": {
         "reference": "Patient/{patient_id}"
      },
       "managingOrganization": {
         "reference": "Organization/{organization_id}"
      }
     }
Request Properties:
Properties Type Description
resourceType
String
Required, Indicates the type of the resource which is “Episode of Care”.
status
String
Required, specifies the current status of the patient. Options : “active”, “inactive”, “suspended”
patient.reference
Reference
Required, Reference to patient Identifier.
managingOrganization
Reference (Patient)
Organization responsible for managing and upkeep.
managingOrganization.reference
String
Required, Specifies the managing organization or hospital Identifier the patient is referenced to.
{
       "resourceType": "EpisodeOfCare",
       "status": "active",
       "patient": {
         "reference": "Patient/1552"
       },
       "managingOrganization": {
         "reference": "Organization/1303"
       }
     }
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Episode of Care”.
id
Identifier
Unique identifier or reference for the created Episode Of Care resource, also known as Episode Of Care ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
managingOrganization
Reference(patient)
Organization responsible for managing and upkeep.
managingOrganization.reference
String
Required, Specifies the managing organization or hospital Identifier the patient is referenced to.
Sample Response:
Status: 201 Created
{
 "resourceType": "EpisodeOfCare",
 "id": "1553",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-02T08:45:15.998+00:00"
 },
 "status": "active",
 "patient": {
   "reference": "Patient/1552"
 },
 "managingOrganization": {
   "reference": "Organization/1303"
 }
}
Error Codes:
Properties Description
201
Successful Request. Indicates that the specified Patient resource has been created.
400
Unsuccessful Request, Invalid Request data.

GET https://deepsepsis.cohere-med.com/api/EpisodeOfCare/{id}

Description: This API fetches the Episode Of Care details based on the identifier.
Request Syntax:

GET https://deepsepsis.cohere-med.com/api/EpisodeOfCare/{EpisodeOfCare_id}

Request Properties:
Properties Type Description
EpisodeOfCare_id
identifier
Episode of Care ID of the patient.
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Episode of Care”.
id
Identifier
Unique identifier or reference for the created Episode Of Care resource, also known as Episode Of Care ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
managingOrganization
Reference(patient)
Organization responsible for managing and upkeep.
managingOrganization.reference
String
Required, Specifies the managing organization or hospital Identifier the patient is referenced to.
Querying with specific parameters:

The GET method can also be used to search or query with specific parameters.

Example: To query/fetch Episode of Care details for a specific patient ID.

Sample Request :

GET  https://deepsepsis.cohere-med.com/api/EpisodeOfCare?patient=1553

Sample Response:

Status: 200 OK
This will fetch Episode of Care details for patient ID 1553.
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource records have been fetched.
400
Unsuccessful Request, Invalid Request data.

Sample Request:

GET https://deepsepsis.cohere-med.com/api/EpisodeOfCare/1553

Sample Response:
Status: 200 OK
{
 "resourceType": "EpisodeOfCare",
 "id": "1553",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-02T08:45:15.998+00:00"
 },
 "status": "active",
 "patient": {
   "reference": "Patient/1552"
 },
 "managingOrganization": {
   "reference": "Organization/1303"
 }
}

PUT https://deepsepsis.cohere-med.com/api/EpisodeOfCare/{id}

Description: This API updates and manages the Episode Of Care resource.
Request Syntax:

PUT https://deepsepsis.cohere-med.com/api/EpisodeOfCare/{EpisodeOfCare_id}
{

Updated Resource Body

}

Request Properties:
Properties Type Description
EpisodeOfCare_id
identifier
Episode of Care ID of the patient.

Sample Request:

PUT https://deepsepsis.cohere-med.com/api/EpisodeOfCare/1553 

*note: The Episode Of Care resource Identifier must be included in the updated request body.

{
       "resourceType": "EpisodeOfCare",
        "id": "1553",
       "status": "suspended",
       "patient": {
         "reference": "Patient/1552"
       },
       "managingOrganization": {
         "reference": "Organization/1303"
       }
     }
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Episode of Care”.
id
Identifier
Unique identifier or reference for the created Episode Of Care resource, also known as Episode Of Care ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
managingOrganization
Reference(patient)
Organization responsible for managing and upkeep.
managingOrganization.reference
String
Required, Specifies the managing organization or hospital Identifier the patient is referenced to.
Sample Response:
Status: 200 OK
{
 "resourceType": "EpisodeOfCare",
 "id": "1553",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-02T10:45:15.998+00:00"
 },
 "status": "suspended",
 "patient": {
   "reference": "Patient/1552"
 },
 "managingOrganization": {
   "reference": "Organization/1303"
 }
}
Error Codes:
Properties Description
200
Successful Request. Indicates that the Episode Of Care resource has been updated.
400
Unsuccessful Request, Invalid Request data or Invalid Episode of Care resource Identifier .

DELETE https://deepsepsis.cohere-med.com/api/EpisodeOfCare/{id}

Description: This API deletes the existing Episode of Care resource from the records.
Request Syntax:

DELETE https://deepsepsis.cohere-med.com/api/EpisodeOfCare/{EpisodeOfCare_id}

Request Properties:
Properties Type Description
EpisodeOfCare_id
identifier
Episode of Care ID of the patient.
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource records have been fetched.
400
Unsuccessful Request, Invalid Request data.

Sample Request:

DELETE https://deepsepsis.cohere-med.com/api/EpisodeOfCare/1553

Sample Response:
Status: 200 OK

The Episode Of Care record of ID 1553 is deleted successfully.

ENCOUNTER API

This API creates and manages encounters in an existing organization. The encounter details essentially contain Admission / Transfer / Discharge information of a patient.
A patient has one Episode of Care with multiple encounters in an existing Organization.
POST https://deepsepsis.cohere-med.com/api/Encounter
Description: This API creates a patient encounter with details mentioned in the input JSON.
Request Body Syntax:
POST https://deepsepsis.cohere-med.com/api/Encounter
{
       "resourceType": "Encounter",
       "status": [“planned” | “arrived” |” triaged “| “in-progress” | “onleave” | “finished” | “cancelled”],
       "type": [
        {
           "coding": [
            {
               "system": "http://snomed.info/sct",
               "code": [“string”],
               "display": [“string”]
            }
          ]
        }
      ],
       "priority": {
         "coding": [
          {
             "system": "http://snomed.info/sct",
             "code": [“string”],
             "display": [“string”]
          }
        ]
      },
       "subject": {
         "reference": "Patient/{Patient_id}"
      },
       "episodeOfCare": [
        {
           "reference": "EpisodeOfCare/{EpisodeOfCare_id}"
        }
      ],
       "period": {
         "start": [Timestamp]
      },
       "location": [
        {
           "location": {
             "reference": "Location/{Location_id}"
          },
           "status": "active",
           "period": {
             "start": [Timestamp]
          }
        }
      ],
       "serviceProvider": {
         "reference": "Organization/{Organization_id}"
      }
     }
Request Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Encounter”.
id
Identifier
Unique identifier or reference for the created Encounter resource, also known as Encounter ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Encounter Status. Options: , “arrived” , “triaged” , “onleave” , “finished” , “cancelled” .
type[0].coding[0].system
URL
URL defining the FHIR standard systems.
type[0].coding[0].code
String
Snomed CT Code used to identify the broad encounter type.
type[0].coding[0].display
String
Name of the encounter type.
priority.coding[0].system
URL
URL defining the FHIR standard systems.
priority.coding[0].code
String
Snomed CT Code used to identify the urgency of the encounter.
priority.coding[0].display
String
Name of the encounter type.
subject.reference
String
Patient ID referenced under the encounter.
EpisodeOfCare[0].reference
String
Episode of Care id mapped to the Patient.
period.start
Timestamp
Specifies the start of the encounter. Timestamp format: YYYY-MM-DDTHH:MM:SS+05:30
location[0].location.reference
String
Location ID mapped to the Patient.
location[0].status
string
Specifies the status of the location. Options: [“planned” , “active”, “reserved” , “completed” ]
location[0].period.start
Timestamp
Timestamp indicating the starting period of the location mapped to the Patient.
serviceProvider.reference
String
The organization (facility) responsible for this encounter. Should be mapped to an Organization/Hospital ID.

Sample Request:

POST https://deepsepsis.cohere-med.com/api/EpisodeOfCare


       "resourceType": "Encounter”,
       "status": "arrived",
       "type": [
         {
           "coding": [
             {
               "system": "http://snomed.info/sct",
               "code": "11429006",
               "display": "Triage"
             }
           ]
         }
       ],
       "priority": {
         "coding": [
           {
             "system": "http://snomed.info/sct",
             "code": "17621005",
             "display": "Emergency"
           }
         ]
       },
       "subject": {
         "reference": "Patient/1552"
       },
       "episodeOfCare": [
         {
           "reference": "EpisodeOfCare/1553"
         }
       ],
       "period": {
         "start": "2020-05-27T09:10:55+05:30"
       },
       "location": [
         {
           "location": {
             "reference": "Location/1452"
           },
           "status": "active",
           "period": {
             "start": "2020-05-27T09:10:55+05:30"
           }
         }
       ],
       "serviceProvider": {
         "reference": "Organization/1303"
       }
     }
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Encounter”.
id
Identifier
Unique identifier or reference for the created Encounter resource, also known as Encounter ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Encounter Status. Options: , “arrived” , “triaged” , “onleave” , “finished” , “cancelled” .
type[0].coding[0].system
URL
URL defining the FHIR standard systems.
type[0].coding[0].code
String
Snomed CT Code used to identify the broad encounter type.
type[0].coding[0].display
String
Name of the encounter type.
priority.coding[0].system
URL
URL defining the FHIR standard systems.
priority.coding[0].code
String
Snomed CT Code used to identify the urgency of the encounter.
priority.coding[0].display
String
Name of the encounter type.
Name of the encounter type.
subject.reference
String
Patient ID referenced under the encounter.
EpisodeOfCare[0].reference
String
Episode of Care id mapped to the Patient.
period.start
Timestamp
Specifies the start of the encounter. Timestamp format: YYYY-MM-DDTHH:MM:SS+05:30
location[0].location.reference
String
Location ID mapped to the Patient.
location[0].status
string
Specifies the status of the location. Options: [“planned” , “active”, “reserved” , “completed” ]
location[0].period.start
Timestamp
Timestamp indicating the starting period of the location mapped to the Patient.
serviceProvider.reference
String
The organization (facility) responsible for this encounter. Should be mapped to an Organization/Hospital ID.
Sample Response:
Status: 201 Created

 "resourceType": "Encounter",
 "id": "1602",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-03T04:04:43.710+00:00"
 },
 "status": "arrived",
 "type": [
   {
     "coding": [
       {
         "system": "http://snomed.info/sct",
         "code": "11429006",
         "display": "Triage"
       }
     ]
   }
 ],
 "priority": {
   "coding": [
     {
       "system": "http://snomed.info/sct",
       "code": "17621005",
       "display": "Emergency"
     }
   ]
 },
 "subject": {
   "reference": "Patient/1552"
 },
 "episodeOfCare": [
   {
     "reference": "EpisodeOfCare/1553"
}
 ],
 "period": {
"start": "2020-05-27T09:10:55+05:30"
 },
 "location": [
   {
     "location": {
       "reference": "Location/1452"
     },
     "status": "active",
     "period": {
       "start": "2020-05-27T09:10:55+05:30"
     }
   }
 ],
 "serviceProvider": {
   "reference": "Organization/1303"
 }
}
Error Codes:
Properties Description
201
Successful Request. Indicates that the specified encounter resource has been created.
400
Unsuccessful Request, Invalid request body or Invalid Patient/Organization/Episode Of Care reference ID.
Description: This API fetches Encounter details from the records for a specified Encounter ID.
Request Syntax:
Request Properties:
Properties Type Description
Encounter_id
Identifier
Encounter_id of the patient.
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Encounter”.
id
Identifier
Unique identifier or reference for the created Encounter resource, also known as Encounter ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Encounter Status. Options: , “arrived” , “triaged” , “onleave” , “finished” , “cancelled” .
type[0].coding[0].system
URL
URL defining the FHIR standard systems.
type[0].coding[0].code
String
Snomed CT Code used to identify the broad encounter type.
type[0].coding[0].display
String
Name of the encounter type.
priority.coding[0].system
URL
URL defining the FHIR standard systems.
priority.coding[0].code
String
Snomed CT Code used to identify the urgency of the encounter.
priority.coding[0].display
String
Name of the encounter type.
subject.reference
String
Patient ID referenced under the encounter.
EpisodeOfCare[0].reference
String
Episode of Care id mapped to the Patient.
period.start
Timestamp
Specifies the start of the encounter. Timestamp format: YYYY-MM-DDTHH:MM:SS+05:30
location[0].location.reference
String
Location ID mapped to the Patient.
location[0].status
string
Specifies the status of the location. Options: [“planned” , “active”, “reserved” , “completed” ]
location[0].period.start
Timestamp
Timestamp indicating the starting period of the location mapped to the Patient.
serviceProvider.reference
String
The organization (facility) responsible for this encounter. Should be mapped to an Organization/Hospital ID.
Querying with specific parameters:

The GET method can also be used to search or query with specific parameters.

Example: To query/fetch Encounter details for a specific Encounter ID and other searchable parameters listed in the Search parameter section

GET  https://deepsepsis.cohere-med.com/api/Encounter?

Example: Request to search encounter details for a specific Patient ID.

Sample Request :

GET  https://deepsepsis.cohere-med.com/api/Encounter?patient=1552

Sample Response:

Status: 200 OK

This will fetch  encounter details for Patient ID 1552.

Example: Request to search for all existing encounter details and include patient details in the response.

Sample Request: 

GET  https://deepsepsis.cohere-med.com/api/Encounter?status=arrived&_include=Encounter:subject

Sample Response:

Status: 200 OK
This will fetch all existing encounters along with patient details.
Search Parameters:
Name Type Description Example
status
Token
Status of the encounter. [ “arrived” | “triaged” | “onleave” | “finished” | “cancelled” ]

https://deepsepsis.cohere-med.com/api/Encounter?status=arrived

service-provider
Reference
The organization (facility) responsible for this encounter.

https://deepsepsis.cohere-med.com/api/Encounter?status=arrived&service-provider=1303

patient
Reference
The patient present at the encounter.
location
Reference
Location the encounter takes place.

https://deepsepsis.cohere-med.com/api/Encounter?location=1452

type
Token
Specific type of encounter.

https://deepsepsis.cohere-med.com/api/Encounter?type=11429006

subject
reference
The patient present at the encounter.

https://deepsepsis.cohere-med.com/api/Encounter?status=arrived&_include=Encounter:subject

Error Codes:
Properties Description
200
Successful Request. Indicates that the Encounter records have been fetched.
400
Unsuccessful Request, Invalid Encounter ID.
Sample Response:
Status: 200 OK

 "resourceType": "Encounter",
 "id": "1602",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-03T04:04:43.710+00:00",
   "source": "#tnOKEbwPt4CeXIpI"
 },
 "status": "arrived",
 "type": [
   {
     "coding": [
       {
         "system": "http://snomed.info/sct",
         "code": "11429006",
         "display": "Triage"
       }
     ]
   }
 ],
 "priority": {
   "coding": [
     {
       "system": "http://snomed.info/sct",
       "code": "17621005",
       "display": "Emergency"
     }
   ]
 },
 "subject": {
   "reference": "Patient/1552"
 },
 "episodeOfCare": [
   {
     "reference": "EpisodeOfCare/1553"
   }
 ],
 "period": {
   "start": "2020-05-27T09:10:55+05:30"
 },
 "location": [
   {
     "location": {
       "reference": "Location/1452"
     },
     "status": "active",
     "period": {
       "start": "2020-05-27T09:10:55+05:30"
     }
   }
 ],
 "serviceProvider": {
   "reference": "Organization/1303"
 }
}

PUT https://deepsepsis.cohere-med.com/api/Encounter/{id}

Description: This API updates and manages the existing Encounter resources.
Request Syntax:

PUT https://deepsepsis.cohere-med.com/api/Encounter/{Encounter_id}
{

Updated Resource Body

}

Request Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Encounter”.
id
Identifier
Unique identifier or reference for the created Encounter resource, also known as Encounter ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Encounter Status. Options: , “arrived” , “triaged” , “onleave” , “finished” , “cancelled” .
type[0].coding[0].system
URL
URL defining the FHIR standard systems.
type[0].coding[0].code
String
Snomed CT Code used to identify the broad encounter type.
type[0].coding[0].display
String
Name of the encounter type.
priority.coding[0].system
URL
URL defining the FHIR standard systems.
priority.coding[0].code
String
Snomed CT Code used to identify the urgency of the encounter.
priority.coding[0].display
String
Name of the encounter type.
Name of the encounter type.
subject.reference
String
Patient ID referenced under the encounter.
EpisodeOfCare[0].reference
String
Episode of Care id mapped to the Patient.
period.start
Timestamp
Specifies the start of the encounter. Timestamp format: YYYY-MM-DDTHH:MM:SS+05:30
location[0].location.reference
String
Location ID mapped to the Patient.
location[0].status
string
Specifies the status of the location. Options: [“planned” , “active”, “reserved” , “completed” ]
location[0].period.start
Timestamp
Timestamp indicating the starting period of the location mapped to the Patient.
serviceProvider.reference
String
The organization (facility) responsible for this encounter. Should be mapped to an Organization/Hospital ID.

Sample Request:

PUT https://deepsepsis.cohere-med.com/api/Encounter/1602

*note: The updated json body must contain the existing Encounter resource ID

"resourceType": "Encounter",
"id": "1602",
"status": "arrived",
"type": [
  {
    "coding": [
      {
        "system": "http://snomed.info/sct",
        "code": "11429006",
        "display": "Triage"
      }
    ]
  }
],
"priority": {
  "coding": [
    {
      "system": "http://snomed.info/sct",
      "code": "17621005",
      "display": "Emergency"
    }
  ]
},
"subject": {
  "reference": "Patient/1552"
},
"episodeOfCare": [
  {
    "reference": "EpisodeOfCare/1553"
  }
],
"period": {
  "start": "2020-05-27T09:10:55+05:30"
},
"location": [
  {
    "location": {
      "reference": "Location/1452"
    },
    "status": "completed",
    "period": {
      "start": "2020-05-27T09:10:55+05:30"
    }
  }
],
"serviceProvider": {
  "reference": "Organization/1303"
}
}
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Encounter”.
id
Identifier
Unique identifier or reference for the created Encounter resource, also known as Encounter ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Encounter Status. Options: , “arrived” , “triaged” , “onleave” , “finished” , “cancelled” .
type[0].coding[0].system
URL
URL defining the FHIR standard systems.
type[0].coding[0].code
String
Snomed CT Code used to identify the broad encounter type.
type[0].coding[0].display
String
Name of the encounter type.
priority.coding[0].system
URL
URL defining the FHIR standard systems.
priority.coding[0].code
String
Snomed CT Code used to identify the urgency of the encounter.
priority.coding[0].display
String
Name of the encounter type.
subject.reference
String
Patient ID referenced under the encounter.
EpisodeOfCare[0].reference
String
Episode of Care id mapped to the Patient.
period.start
Timestamp
Specifies the start of the encounter. Timestamp format: YYYY-MM-DDTHH:MM:SS+05:30
location[0].location.reference
String
Location ID mapped to the Patient.
location[0].status
string
Specifies the status of the location. Options: [“planned” , “active”, “reserved” , “completed” ]
location[0].period.start
Timestamp
Timestamp indicating the starting period of the location mapped to the Patient.
serviceProvider.reference
String
The organization (facility) responsible for this encounter. Should be mapped to an Organization/Hospital ID.
Sample Response:
Status: 200 OK

 "resourceType": "Encounter",
 "id": "1602",
 "meta": {
   "versionId": "3",
   "lastUpdated": "2020-09-03T07:50:47.068+00:00"
 },
 "status": "arrived",
 "type": [
   {
     "coding": [
       {
         "system": "http://snomed.info/sct",
         "code": "11429006",
         "display": "Triage"
       }
     ]
   }
 ],
 "priority": {
   "coding": [
     {
       "system": "http://snomed.info/sct",
       "code": "17621005",
       "display": "Emergency"
     }
   ]
 },
 "subject": {
   "reference": "Patient/1552"
 },
 "episodeOfCare": [
   {
     "reference": "EpisodeOfCare/1553"
   }
 ],
 "period": {
   "start": "2020-05-27T09:10:55+05:30"
 },
 "location": [
   {
     "location": {
       "reference": "Location/1452"
     },
     "status": "completed",
     "period": {
       "start": "2020-05-27T09:10:55+05:30"
     }
   }
 ],
 "serviceProvider": {
   "reference": "Organization/1303"
 }
}
Error Codes:
Properties Description
200
Successful Request. Indicates that the encounter has been updated.
400
Unsuccessful Request, Invalid Request data or Invalid Episode of Care/Organization/Location resource ID.
DELETE https://deepsepsis.cohere-med.com/api/Encounter/{id}
Description: This API deletes the encounter details for the specified Encounter ID.
Request Syntax:

DELETE https://deepsepsis.cohere-med.com/api/Encounter/{Encounter_id}

Request Properties:
Properties Type Description
Encounter_id
Identifier
Encounter_id of the patient.
Error Codes:
Properties Description
200
Successful Request. Indicates that the specified encounter resource has been deleted.
400
Unsuccessful Request, Invalid Encounter ID.

Sample Request:

DELETE https://deepsepsis.cohere-med.com/api/Encounter/1602

Sample Response:
Status: 200 OK

This deletes the encounter details for the encounter ID 1602 from the records.

SERVICE REQUEST API

This API creates and manages the records of requests for, Labs to be planned, done for a patient in the healthcare system. 
Service request API is essentially used before creating records or ingesting data for Labs values for a patient.
POST https://deepsepsis.cohere-med.com/api/ServiceRequest
Request Body Syntax:
{
       "resourceType": "ServiceRequest",
       "Status":[draft” | “active” | “on-hold” | “revoked” | “completed” | “entered-in-error” |” unknown”] , 
       "intent": [“proposal” | “plan”  | “directive” | “order” | “original-order” | “reflex-order” | “filler-order” |  “instance-order”] ,
       "code": {
         "coding": [
          {
             "system": "http://snomed.info/sct",
             "code": "261904005"       //Snomed CT codes for what is being requested.
          }
        ],
         "text": “Lab tests”  //Name of the Request
      },
       "subject": {
         "reference": "Patient/{Patient_ID}"            //Specify the Patient ID for whom the request has been made.
      },
       "encounter": {
         "reference": "Encounter/{Encounter_ID}"  //Specify the Encounter  ID for whom the request has been made.
      },
       "occurrenceDateTime": "2020-05-30T09:45:00+05:30"// Time at which the request has been raised.
       "locationReference": [
        {
           "reference": "Location/{Location_ID}"    // Specify the Location ID mapped with the Patient ID.      
         }
      ],
       "reasonCode": [
        {
           "text": [“string”]    //Explanation/Justification for service or service
        }
      ]
     }
Request Properties:
Properties Type Description
resourceType
String
Required, Indicates the type of the resource which is “Service Request”.
status
String
Required, Service Request status. Options: “draft” , “active” , “on-hold” , “revoked” , “completed” ,“entered-in-error” , “unknown”.
intent
Code, string
Required, Specifies the request Intent. Options: “proposal” , “plan” , “directive” ,“order” , “original-order” , “reflex-order” , “filler-order” , “instance-order”
Code.coding[ ].system
URL
Required, URL defining the FHIR standard systems, which is Snomed CT in this case.
Code.coding[ ].code
String
Required, Snomed CT codes for what is being requested. Refer Snomed CT Service Request to map request to it’s Snomed CT codes.
code.text
String
Optional, Specifies the name of the Request.
subject.reference
Reference
Required, Patient ID for whom the request has been made.
encounter.reference
Reference
Required, Encounter ID for whom the request has been made.
occurrenceDateTime
Timestamp
Required, Time at which the request is raised in the format YYYY-MM-DDTHH:MM:SS+05:30
locationReference.reference
Reference
Required, Required, LocationID mapped with the Patient ID.
reasonCode.text
String
Optional, Justification for the service request.

Sample Request:

POST https://deepsepsis.cohere-med.com/api/ServiceRequest

Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “ServiceRequest”.
id
Identifier
Unique identifier or reference for the created Service Request resource, also known as Service Request ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Service Request status.
intent
String
Specifies the request Intent.
Code.coding[ ].system
URL
URL defining the FHIR standard systems, which is Snomed CT in this case.
Code.coding[ ].code
String
Snomed CT codes for what is being requested.
code.text
String
Specifies the name of the Request.
subject.reference
Reference
Patient ID for whom the request has been made.
encounter.reference
Reference
Encounter ID for whom the request has been made.
occurrenceDateTime
Timestamp
Time at which the request is raised in the format YYYY-MM-DDTHH:MM:SS+05:30
locationReference.reference
Reference
Required, LocationID mapped with the Patient ID.
reasonCode.text
String
Justification for the service request.
Sample Response:
Status: 201 Created
{
 "resourceType": "ServiceRequest",
 "id": "1652",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-03T09:06:08.942+00:00"
 },
 "status": "active",
 "intent": "original-order",
 "code": {
   "coding": [
     {
       "system": "http://snomed.info/sct",
       "code": "261904005"
     }
   ],
   "text": "Lab Tests"
 },
 "subject": {
   "reference": "Patient/1552"
 },
 "encounter": {
   "reference": "Encounter/1602"
 },
 "occurrenceDateTime": "2020-05-30T09:45:00+05:30",
 "locationReference": [
   {
     "reference": "Location/1452"
   }
 ],
 "reasonCode": [
   {
     "text": "Lab Tests"
   }
 ]
}
Error Codes:
Properties Description
201
Successful Request. Indicates that the Service Request resource has been created.
400
Unsuccessful Request, Invalid request body or Invalid Patient/Encounter/Location ID.
GET https://deepsepsis.cohere-med.com/api/ServiceRequest/{id}
Description: This API fetches service request details for a specific Service Request ID.
Request Syntax:
GET https://deepsepsis.cohere-med.com/api/ServiceRequest/{ServiceRequest_id}
Request Properties:
Properties Type Description
ServiceRequest_id
Identifier
ServiceRequest ID for an existing request.
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “ServiceRequest”.
id
Identifier
Unique identifier or reference for the created Service Request resource, also known as Service Request ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Service Request status.
intent
Code, String
Specifies the request Intent.
Code.coding[ ].system
URL
URL defining the FHIR standard systems, which is Snomed CT in this case.
Code.coding[ ].code
Code, String
Snomed CT codes for what is being requested.
code.text
String
Specifies the name of the Request.
subject.reference
Reference
Patient ID for whom the request has been made.
encounter.reference
Reference
Encounter ID for whom the request has been made.
occurrenceDateTime
Timestamp
Time at which the request is raised in the format YYYY-MM-DDTHH:MM:SS+05:30
locationReference.reference
Reference
Required, LocationID mapped with the Patient ID.
reasonCode.text
String
Justification for the service request.
Error Codes:
Properties Description
200
Successful Request. Indicates that the Service Request records have been fetched.
400
Unsuccessful Request, Invalid Service Request ID.

Sample Request:

GET https://deepsepsis.cohere-med.com/api/ServiceRequest/1652

Sample Response:
Status: 200 OK
{
 "resourceType": "ServiceRequest",
 "id": "1652",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-03T09:06:08.942+00:00",
   "source": "#6giHiEYnK88X25Q9"
 },
 "status": "active",
 "intent": "original-order",
 "code": {
   "coding": [
     {
       "system": "http://snomed.info/sct",
       "code": "261904005"
     }
   ],
   "text": "Lab Tests"
 },
 "subject": {
   "reference": "Patient/1552"
 },
 "encounter": {
   "reference": "Encounter/1602"
 },
 "occurrenceDateTime": "2020-05-30T09:45:00+05:30",
 "locationReference": [
   {
     "reference": "Location/1452"
   }
 ],
 "reasonCode": [
   {
     "text": "Lab Tests"
   }
 ]
}
PUT https://deepsepsis.cohere-med.com/api/ServiceRequest/{id}
Description: This API updates and manages the existing Service Request Resources.
Request Syntax:

PUT https://deepsepsis.cohere-med.com/api/ServiceRequest/{ServiceRequest_id}
{

Updated Service Request Body

}

Request Properties:
Properties Type Description
ServiceRequest_id
Identifier
ServiceRequest ID for an existing request.

Sample Request:

PUT https://deepsepsis.cohere-med.com/api/ServiceRequest/1652

*note: The updated request body must contain the existing Service Request ID.

{
       "resourceType": "ServiceRequest",
       "id" :"1652",
       "status": "active",
       "intent": "original-order",
       "code": {
         "coding": [
           {
             "system": "http://snomed.info/sct",
             "code": "261904005"
           }
         ],
         "text": "Test for Sodium, Creatinine"
       },
       "subject": {
         "reference": "Patient/1552"
       },
       "encounter": {
         "reference": "Encounter/1602"
       },
       "occurrenceDateTime": "2020-05-30T09:45:00+05:30",
       "locationReference": [
         {
           "reference": "Location/1452"
         }
       ],
       "reasonCode": [
         {
           "text": "Lab Tests for Review"
         }
       ]
     }
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “ServiceRequest”.
id
Identifier
Unique identifier or reference for the created Service Request resource, also known as Service Request ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Service Request status.
intent
String
Specifies the request Intent.
Code.coding[ ].system
URL
URL defining the FHIR standard systems, which is Snomed CT in this case.
Code.coding[ ].code
String
Snomed CT codes for what is being requested.
code.text
String
Specifies the name of the Request.
subject.reference
Reference
Patient ID for whom the request has been made.
encounter.reference
Reference
Encounter ID for whom the request has been made.
occurrenceDateTime
Timestamp
Time at which the request is raised in the format YYYY-MM-DDTHH:MM:SS+05:30
locationReference.reference
Reference
Required, LocationID mapped with the Patient ID.
reasonCode.text
String
Justification for the service request.
Sample Response:
Status: 200 OK
{
 "resourceType": "ServiceRequest",
 "id": "1652",
 "meta": {
   "versionId": "2",
   "lastUpdated": "2020-09-03T12:22:14.356+00:00"
 },
 "status": "active",
 "intent": "original-order",
 "code": {
   "coding": [
     {
       "system": "http://snomed.info/sct",
       "code": "261904005"
     }
   ],
   "text": "Test for Sodium, Creatinine"
 },
 "subject": {
   "reference": "Patient/1552"
 },
 "encounter": {
   "reference": "Encounter/1602"
 },
 "occurrenceDateTime": "2020-05-30T09:45:00+05:30",
 "locationReference": [
   {
     "reference": "Location/1452"
   }
 ],
 "reasonCode": [
   {
     "text": "Lab Tests for Review"
   }
 ]
}
Error Codes:
Properties Description
200
Successful Request. Indicates that the Service Request resource has been updated.
400
Unsuccessful Request, Invalid Request data or Invalid Organization/Location resource ID .
DELETE https://deepsepsis.cohere-med.com/api/ServiceRequest/{id}
Description: This API deletes the Service Request details of the specified Service Request ID from the records.
Request Syntax:
DELETE https://deepsepsis.cohere-med.com/api/ServiceRequest/{ServiceRequest_id}
Request Properties:
Properties Type Description
ServiceRequest_id
Identifier
ServiceRequest ID for an existing request.
Error Codes:
Properties Description
200
Successful Request. Indicates that the Service Request has been deleted.
400
Unsuccessful Request, Invalid Service Request ID.
Sample Request: DELETE https://deepsepsis.cohere-med.com/api/ServiceRequest/1652
Sample Response:
Status: 200 OK

The Service Request details of 1652 ID is deleted from the database.

OBSERVATION API

Observation resources are a central element in healthcare, used to capture demographic characteristics.
This API creates and manages the Observation records, essentially Labs and Vitals/Physiological parameters of a patient whose record is active in an Organization.
POST https://deepsepsis.cohere-med.com/api/Observation
Description: This API creates the Observation records for an existing patient in the Organization.
Request Body Syntax:
POST https://deepsepsis.cohere-med.com/api/Observation
{
       "resourceType": "Observation",
         "tag": [
          {
             "code": [“code string”],   // Code that specifies what is being observed.
             "display": [“string”]   //Name of the Observation
          }
        ]
      },
       "status": [“registered” | “preliminary” | “final” | “amended”]// Observation Status
 "category": [                       //Classification of type of Observation
  {
     "coding": [
      {
         "system": "http://snomed.info/sct",   //FHIR system standard URL
         "code": [“code string”],                          //Snomed CT code for the Observation
         "display": [“string”]       //Name of the Observation
      }
    ]
  }
],
       "code": {                      //Type of Observation
         "coding": [
          {
             "code": [“code string”]   //Code for the Type of Observation
          }
        ]
      },
       "subject": {
         "reference": "Patient/{Patient_ID}"   //Reference to Patient ID
      },
       "encounter": {
         "reference": "Encounter/{Encounter_ID}" //Reference to Encounter ID
      },
       "effectiveDateTime": [Timestamp],    //Time instance
       "component": [          //Component Results, essentially a list containing the Observations.
  {
     "code": {
       "coding": [
        {
           "id": [“Observation Identifier”],   // Unique Identifier for every observation
           "system": "http://snomed.info/sct",  //FHIR system standard URL
           "code": [“Code string”], //snomed CT code for the observation.
           "display": [“string”] //name of the Observation
        }
      ]
    },
     "valueQuantity":     //Observation Value Quantity
 
       "value": [value],    //Value of the Observation
               "unit":[“string"] //Units of the Observation
                   }
}
]
}
Request Properties:
Properties Type Description
resourceType
String
Required, Indicates the type of the resource which is “Observation”.
tag[0].code
String
Required, Code that specifies what is being observed.
tag[0].display
String
Optional, Name of the Observation.
status
String
Required, Observation Status. Options: [“registered” , “preliminary” , “final” , “amended”]
category[0].coding[0].system
String
Required, URL defining the FHIR standard systems, which is Snomed CT in this case.
category[0].coding[0].code
String
Required, snomedCT code for the Observation.
category[0].coding[0].display
String
Optional,Name of the type of Observation.
code.coding[0].code
String
Required, Code for the Observation. Refer Codes for types of Observations.
subject.reference
Reference
Required, Reference to Patient ID.
encounter.reference
Reference
Required, Encounter ID mapped to the Patient.
effectiveDateTime
Timestamp
Required, Timestamp when the observation was recorded in the format YYYY-MM-DDTHH:MM:SS+05:30
component
List []
List of recorded Observations.
Component[ ].code.coding[0].id
Identifier
Required, Observation Identifier.
Component[ ].code.coding[0].system
URL
Required, URL defining the FHIR standard systems, which is Snomed CT in this case.
Component[ ].code.coding[0].code
String
Required, Snomed CT code for the Observation.
Component[ ].code.coding[0].display
String
Optional, Name of the Observation.
Component[ ].valueQuantity.value
Float
Required, Value of the Observation.
Component[ ].valueQuantity.unit
Unit
Optional, Unit of the Observation
Sample Request: POST https://deepsepsis.cohere-med.com/api/Observation
{
       "resourceType": "Observation",
         "tag": [
           {
             "code": "cm_vital",
             "display": "Observation"
           }
         ],
       "status": "final",
 "category": [
   {
     "coding": [
       {
         "system": "http://snomed.info/sct",
         "code": "260410005",
         "display": "Vital"
       }
     ]
   }
 ],
       "code": {
         "coding": [
           {
             "code": "cm_vital"
           }
         ]
       },
       "subject": {
         "reference": "Patient/1552"
       },
       "encounter": {
         "reference": "Encounter/1602"
       },
       "effectiveDateTime": "2020-03-25T06:05:00+05:30",
       "component": [
   {
     "code": {
       "coding": [
         {
           "id": "vital.systolic",
           "system": "http://snomed.info/sct",
           "code": "163030003",
           "display": "Systolic (mm Hg)"
         }
       ]
     },
     "valueQuantity": {
       "value": 91,
               "unit":"(mm Hg)"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.diastolic",
           "system": "http://snomed.info/sct",
           "code": "163031004",
           "display": "Diastolic (mm Hg)"
         }
       ]
     },
     "valueQuantity": {
       "value": 56,
               "unit":"(mm Hg)"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.heartrate",
           "system": "http://snomed.info/sct",
           "code": "364075005",
           "display": "Bpm"
         }
       ]
     },
     "valueQuantity": {
       "value": 73,
               "unit":"bpm"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.rrrate",
           "system": "http://snomed.info/sct",
           "code": "86290005",
           "display": "Respiratory Rate (bpm)"
         }
       ]
     },
     "valueQuantity": {
       "value": 16,
               "unit":"Bpm"
     }
   }
 ]
     }
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Observation”
id
Identifier
Unique identifier or reference for the created Observation resource, also known as Observation ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Observation Status.
category[0].coding[0].system
String
URL defining the FHIR standard systems, which is Snomed CT in this case.
category[0].coding[0].code
String
snomedCT code for the Observation.
Code.coding[ ].code
String
Snomed CT codes for what is being requested. Refer Snomed CT Service Request to map request to it’s Snomed CT codes.
subject.reference
Reference
Reference to Patient ID.
encounter.reference
Reference
Encounter ID mapped to the Patient.
effectiveDateTime
Timestamp
Time at which the request is raised in the format YYYY-MM-DDTHH:MM:SS+05:30
component
List []
List of recorded Observations.
Component[ ].code.coding[0].id
Identifier
Observation Identifier.
Component[ ].code.coding[0].system
URL
URL defining the FHIR standard systems, which is Snomed CT in this case.
Component[ ].code.coding[0].code
String
Snomed CT code for the Observation.
Component[ ].code.coding[0].display
String
Name of the Observation.
Component[ ].valueQuantity.value
Float
Value of the Observation.
Component[ ].valueQuantity.unit
Unit
Unit of the Observation
Sample Response:
Status: 201 Created

 "resourceType": "Observation",
 "id": "1702",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-03T13:32:23.243+00:00"
 },
 "status": "final",
 "category": [
   {
     "coding": [
       {
         "system": "http://snomed.info/sct",
         "code": "260410005",
         "display": "Vital"
       }
     ]
   }
 ],
 "code": {
   "coding": [
     {
       "code": "cm_vital"
     }
   ]
 },
 "subject": {
   "reference": "Patient/1552"
 },
 "encounter": {
   "reference": "Encounter/1602"
 },
 "effectiveDateTime": "2020-03-25T06:05:00+05:30",
 "component": [
   {
     "code": {
       "coding": [
         {
           "id": "vital.systolic",
           "system": "http://snomed.info/sct",
           "code": "163030003",
           "display": "Systolic (mm Hg)"
         }
       ]
     },
     "valueQuantity": {
       "value": 91,
       "unit": "(mm Hg)"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.diastolic",
           "system": "http://snomed.info/sct",
           "code": "163031004",
           "display": "Diastolic (mm Hg)"
         }
       ]
     },
     "valueQuantity": {
       "value": 56,
       "unit": "(mm Hg)"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.heartrate",
           "system": "http://snomed.info/sct",
           "code": "364075005",
           "display": "Bpm"
         }
       ]
     },
     "valueQuantity": {
       "value": 73,
       "unit": "bpm"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.rrrate",
           "system": "http://snomed.info/sct",
           "code": "86290005",
           "display": "Respiratory Rate (bpm)"
         }
       ]
     },
     "valueQuantity": {
       "value": 16,
       "unit": "Bpm"
     }
   }
 ]
}
Error Codes:
Properties Description
201
Successful Request. Indicates that the Observation resource has been created.
400
Unsuccessful Request, Invalid request body or Invalid Patient/Encounter ID.
GET https://deepsepsis.cohere-med.com/api/Observation/{id}
Description: This API fetches all existing Observation records for a given Observation ID.
Request Syntax:
GET https://deepsepsis.cohere-med.com/api/Observation/{Observation_id}
Request Properties:
Properties Type Description
Observation_id
Identifier
Observation ID of an existing Observation resource.
Sample Request: GET https://deepsepsis.cohere-med.com/api/Observation/1702
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Observation”
id
Identifier
Unique identifier or reference for the created Observation resource, also known as Observation ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Observation Status.
category[0].coding[0].system
String
URL defining the FHIR standard systems, which is Snomed CT in this case.
category[0].coding[0].code
String
snomedCT code for the Observation.
category[0].coding[0].display
String
Name of the type of Observation.
Code.coding[ ].code
String
Snomed CT codes for what is being requested. Refer Snomed CT Service Request to map request to it’s Snomed CT codes.
subject.reference
Reference
Reference to Patient ID.
encounter.reference
Reference
Encounter ID mapped to the Patient.
effectiveDateTime
Timestamp
Time at which the request is raised in the format YYYY-MM-DDTHH:MM:SS+05:30
component
List []
List of recorded Observations.
Component[ ].code.coding[0].id
Identifier
Observation Identifier.
Component[ ].code.coding[0].system
URL
URL defining the FHIR standard systems, which is Snomed CT in this case.
Component[ ].code.coding[0].code
String
Snomed CT code for the Observation.
Component[ ].code.coding[0].display
String
Name of the Observation.
Component[ ].valueQuantity.value
Float
Value of the Observation.
Component[ ].valueQuantity.unit
Unit
Unit of the Observation
Error Codes:
Properties Description
200
Successful Request. Indicates that the Observation records have been fetched.
400
Unsuccessful Request, Invalid Observation ID.

Querying with specific parameters:

The GET method can also be used to search or query with specific parameters.

Example: To query/fetch Encounter details for a specific Encounter ID and other searchable parameters listed in the Search parameter section.

Example: Query to search for all Observations for patient id 1552

Request:
GET https://deepsepsis.cohere-med.com/api/Observation?patient=1552
Response:
Status: 200 OK
Fetches all Observation records for Patient ID 1552.
Search Parameteres:
Name Type Description Example
status
token
Status of the Observation. Options: [“registered” , “preliminary” , “final” , “amended”]
encounter
Reference
Encounter ID mapped to the Patient.
subject
Reference
Patient ID referenced in the Observation resource.
Sample Response:
Status: 200 OK
{
 "resourceType": "Observation",
 "id": "1702",
 "meta": {
   "versionId": "1",
   "lastUpdated": "2020-09-03T13:32:23.243+00:00",
   "source": "#4L7jIuxbvjUhrtEV"
 },
 "status": "final",
 "category": [
   {
     "coding": [
       {
         "system": "http://snomed.info/sct",
         "code": "260410005",
         "display": "Vital"
       }
     ]
   }
 ],
 "code": {
   "coding": [
     {
       "code": "cm_vital"
     }
   ]
 },
 "subject": {
   "reference": "Patient/1552"
 },
 "encounter": {
   "reference": "Encounter/1602"
 },
 "effectiveDateTime": "2020-03-25T06:05:00+05:30",
 "component": [
   {
     "code": {
       "coding": [
         {
           "id": "vital.systolic",
           "system": "http://snomed.info/sct",
           "code": "163030003",
           "display": "Systolic (mm Hg)"
         }
       ]
     },
     "valueQuantity": {
       "value": 91,
       "unit": "(mm Hg)"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.diastolic",
           "system": "http://snomed.info/sct",
           "code": "163031004",
           "display": "Diastolic (mm Hg)"
         }
       ]
     },
     "valueQuantity": {
       "value": 56,
       "unit": "(mm Hg)"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.heartrate",
           "system": "http://snomed.info/sct",
           "code": "364075005",
           "display": "Bpm"
         }
       ]
     },
     "valueQuantity": {
       "value": 73,
       "unit": "bpm"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.rrrate",
           "system": "http://snomed.info/sct",
           "code": "86290005",
           "display": "Respiratory Rate (bpm)"
         }
       ]
     },
     "valueQuantity": {
       "value": 16,
       "unit": "Bpm"
     }
   }
 ]
}
PUT https://deepsepsis.cohere-med.com/api/ServiceRequest/{id}
Description: This API updates and manages observation resources for a specified Observation ID.
Request Syntax:

PUT https://deepsepsis.cohere-med.com/api/Observation/{Observation_id}
{

Updated Service Request Body

}

Request Properties:
Properties Type Description
Observation_id
Identifier
Observation ID of an existing Observation resource.

Sample Request:

PUT https://deepsepsis.cohere-med.com/api/Observation/1702

*note: The updated JSON body must contain the existing Observation Resource ID.

{
       "resourceType": "Observation",
       "id":"1702",
         "tag": [
           {
             "code": "cm_vital",
             "display": "Observation"
           }
         ],
       "status": "final",
 "category": [
   {
     "coding": [
       {
         "system": "http://snomed.info/sct",
         "code": "260410005",
         "display": "Vital"
       }
     ]
   }
 ],
       "code": {
         "coding": [
           {
             "code": "cm_vital"
           }
         ]
       },
       "subject": {
         "reference": "Patient/1552"
       },
       "encounter": {
         "reference": "Encounter/1602"
       },
       "effectiveDateTime": "2020-03-25T08:05:00+05:30",
       "component": [
   {
     "code": {
       "coding": [
         {
           "id": "vital.systolic",
           "system": "http://snomed.info/sct",
           "code": "163030003",
           "display": "Systolic (mm Hg)"
         }
       ]
     },
     "valueQuantity": {
       "value": 91,
               "unit":"(mm Hg)"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.diastolic",
           "system": "http://snomed.info/sct",
           "code": "163031004",
           "display": "Diastolic (mm Hg)"
         }
       ]
     },
     "valueQuantity": {
       "value": 76,
               "unit":"(mm Hg)"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.heartrate",
           "system": "http://snomed.info/sct",
           "code": "364075005",
           "display": "Bpm"
         }
       ]
     },
     "valueQuantity": {
       "value": 73,
               "unit":"bpm"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.rrrate",
           "system": "http://snomed.info/sct",
           "code": "86290005",
           "display": "Respiratory Rate (bpm)"
         }
       ]
     },
     "valueQuantity": {
       "value": 20,
               "unit":"Bpm"
     }
   }
 ]
     }
Response Properties:
Properties Type Description
resourceType
String
Indicates the type of the resource which is “Observation”
id
Identifier
Unique identifier or reference for the created Observation resource, also known as Observation ID.
meta
List []
Meta data that provides technical and workflow context to the resource created.
meta.versionId
Identifier
Version id of the resource. This is subjected to change each time the content of the resource changes.
meta.lastUpdated
Time Instant
Time at which the resource was last updated/ created.
status
String
Observation Status.
category[0].coding[0].system
String
URL defining the FHIR standard systems, which is Snomed CT in this case.
category[0].coding[0].code
String
snomedCT code for the Observation.
Code.coding[ ].code
String
Snomed CT codes for what is being requested. Refer Snomed CT Service Request to map request to it’s Snomed CT codes.
subject.reference
Reference
Reference to Patient ID.
encounter.reference
Reference
Encounter ID mapped to the Patient.
effectiveDateTime
Timestamp
Time at which the request is raised in the format YYYY-MM-DDTHH:MM:SS+05:30
component
List []
List of recorded Observations.
Component[ ].code.coding[0].id
Identifier
Observation Identifier.
Component[ ].code.coding[0].system
URL
URL defining the FHIR standard systems, which is Snomed CT in this case.
Component[ ].code.coding[0].code
String
Snomed CT code for the Observation.
Component[ ].code.coding[0].display
String
Name of the Observation.
Component[ ].valueQuantity.value
Float
Value of the Observation.
Component[ ].valueQuantity.unit
Unit
Unit of the Observation
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource has been updated.
400
Unsuccessful Request, Invalid Request data or Invalid Patient/Encounter/Observation resource ID .
Sample Response:
Status: 200 OK
{
 "resourceType": "Observation",
 "id": "1702",
 "meta": {
   "versionId": "2",
   "lastUpdated": "2020-09-03T14:04:24.994+00:00"
 },
 "status": "final",
 "category": [
   {
     "coding": [
       {
         "system": "http://snomed.info/sct",
         "code": "260410005",
         "display": "Vital"
       }
     ]
   }
 ],
 "code": {
   "coding": [
     {
       "code": "cm_vital"
     }
   ]
 },
 "subject": {
   "reference": "Patient/1552"
 },
 "encounter": {
   "reference": "Encounter/1602"
 },
 "effectiveDateTime": "2020-03-25T08:05:00+05:30",
 "component": [
   {
     "code": {
       "coding": [
         {
           "id": "vital.systolic",
           "system": "http://snomed.info/sct",
           "code": "163030003",
           "display": "Systolic (mm Hg)"
         }
       ]
     },
     "valueQuantity": {
       "value": 91,
       "unit": "(mm Hg)"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.diastolic",
           "system": "http://snomed.info/sct",
           "code": "163031004",
           "display": "Diastolic (mm Hg)"
         }
       ]
     },
     "valueQuantity": {
       "value": 76,
       "unit": "(mm Hg)"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.heartrate",
           "system": "http://snomed.info/sct",
           "code": "364075005",
           "display": "Bpm"
         }
       ]
     },
     "valueQuantity": {
       "value": 73,
       "unit": "bpm"
     }
   },
   {
     "code": {
       "coding": [
         {
           "id": "vital.rrrate",
           "system": "http://snomed.info/sct",
           "code": "86290005",
           "display": "Respiratory Rate (bpm)"
         }
       ]
     },
     "valueQuantity": {
       "value": 20,
       "unit": "Bpm"
     }
   }
 ]
}
DELETE https://deepsepsis.cohere-med.com/api/Observation/{id}
Description: This API deletes the Observation resources for the specified Observation ID.
Request Syntax:
DELETE https://deepsepsis.cohere-med.com/api/Observation/{Observation_id}
Request Properties:
Properties Type Description
Observation_id
Identifier
Observation ID of an existing Observation resource.
Error Codes:
Properties Description
200
Successful Request. Indicates that the resource records have been fetched.
400
Unsuccessful Request, Invalid Request data.

Sample Request:

DELETE https://deepsepsis.cohere-med.com/api/Observation/1702

Sample Response:
Status: 200 OK

The observation resource for Observation ID 1702 is deleted successfully.

DIAGNOSTIC REPORT API

Diagnostic Report is a set of Information that is provided by a diagnostic service when investigations are complete. This API creates and manages Diagnostic reports for a given Patient.
POST https://deepsepsis.cohere-med.com/api/DiagnosticReport
Request Body Syntax:
POST https://deepsepsis.cohere-med.com/api/DiagnosticReport
{
       "resourceType": "DiagnosticReport",
       "basedOn": [
        {
           "reference": "ServiceRequest/{ServiceRequest_ID}" //Reference to Service Request ID
        }
      ],
       "status": [“registered” | “partial” | “preliminary” | “final”], //Diagnostic Report Status
       "category": [
        {
           "coding": [
            {
               "system": "http://snomed.info/sct", //FHIR URL Standard
               "code": [“code string”], //Code for this Diagnostic Report
               "display":[ "string"] //Name for the Diagnostic Report
            }
          ]
        }
      ],
        "code": {
         "coding": [