Questionnaire/Response Interaction
As a response to a ServiceDefinition.$evaluate operation to request clinical support guidance, a selected CDSS returns a GuidanceResponse resource to the EMS.
If further evaluation is required in the current triage journey, the CDSS will create a Questionnaire resource to contain a relevant question based on information received from the EMS.
The GuidanceResponse resource will carry a reference to the Questionnaire resource in its dataRequirement element in order to return it to the EMS.
As a response to a Questionnaire, the EMS will create and populate a QuestionnaireResponse to carry the answers from the EMS user.
Request Headers
The following HTTP request headers are supported for this interaction:
| Header | Value | Conformance | 
|---|---|---|
Accept | 
      The Accept header indicates the format of the response the client is able to understand, this will be one of the following application/fhir+json or application/fhir+xml. See the RESTful API Content types section. | 
      MAY | 
Authorization | 
      The Authorization header MUST carry a base64url encoded JSON web token. See the RESTful API Security section. | 
      MUST | 
Create Questionnaire
This action is performed by the CDSS and it occurs in response to a ServiceDefinition.$evaluate operation posted by the EMS when the inputData element received does not contain all the information needed to complete the triage journey.
It is done using the FHIR RESTful create interaction as below:
The new resource is created in a server-assigned location.
Response
Success
- MUST return a 
201CREATED HTTP status code on successful execution of the interaction. - MUST return a response body containing a payload with an 
OperationOutcomeresource that conforms to the Operation Outcome FHIR resource. - MUST return an HTTP 
Locationresponse header containing the full resolvable URL to the newly createdQuestionnaire.- The URL will contain the ‘server’ assigned 
logical Idof the newQuestionnaireresource. - The URL format MUST be: 
https://[host]/[path]?_id=[id]. - When a resource has been created it will have a 
versionIdof 1. 
 - The URL will contain the ‘server’ assigned 
 
The table below summarises the create interaction HTTP response code and the values expected to be conveyed in the successful response body OperationOutcome payload:
| HTTP Code | issue-severity | issue-type | Details.Code | Details.Display | 
|---|---|---|---|---|
| 201 | information | informational | RESOURCE_CREATED | New resource created | 
Failure
The following errors can be triggered when performing this operation:
Get Questionnaire
This action is performed by the EMS in order to get a Questionnaire from a selected CDSS.
The EMS will get the Questionnaire returned by the CDSS, using as a parameter its returned logical id.
The interaction is performed by an FHIR RESTful read interaction.
This read interaction accesses the current contents of the selected Questionnaire.
Parameters
_id
The parameter _id refers to the logical id of the Questionnaire resource and can be used when the context specifies the Questionnaire resource type.  
This read request finds the Questionnaire resource with the given id (there can only be one resource for a given id).
Further details relating to the search parameter _id are available.
Read Response
Success
- MUST return a 
200OK HTTP status code on successful execution of the interaction. - The returned resource MUST have an 
idelement with a value that is the [id]. 
Failure
The following errors can be triggered when performing this operation:
- Invalid parameter (if using the ‘_format’ parameter without a mime type recognised by a CDSS or EMS server).
 - Resource not found
 
Questionnaire: Implementation Guidance
View CDS implementation guidance for a Questionnaire.
QuestionnaireResponse
On presenting the questions contained in the returned Questionnaire to the user, the EMS will create and populate an answering QuestionnaireResponse based upon the user’s response(s).
The latter resource will be referenced in the inputData parameter of the next ServiceDefinition.$evaluate sent to the CDSS.
The EMS will create the QuestionnaireResponse using the same FHIR RESTful create interaction as outlined above for the creation of a Questionnaire. The CDSS can request this resource from the EMS using the HTTP GET verb and _id parameter as outlined above for the request of a Questionnaire.
QuestionnaireResponse: Implementation Guidance
View CDS implementation guidance for a QuestionnaireResponse.
Observation
On receipt of the QuestionnaireResponse, the CDSS will use its contents to create an assertion, typically as an Observation resource, a reference to which is added to the GuidanceResponse.outputParameters returned to the EMS. Note that QuestionnaireResponse and assertions will typically be one to one, but do not have to be. A CDSS can create multiple assertions from a single QuestionnaireResponse, and may also use multiple QuestionnaireResponses to be sure of a single assertion.
The CDSS will create the Observation (or other resource appropriate for the assertion) using the same FHIR RESTful create interaction as outlined above for the creation of a Questionnaire.