FHIR CI-Build

This is the Continuous Integration Build of FHIR (will be incorrect/inconsistent at times).
See the Directory of published versions

Example OperationDefinition/StructureDefinition-questionnaire (JSON)

FHIR Infrastructure Work GroupMaturity Level: N/AStandards Status: Informative

Raw JSON (canonical form + also see JSON Format Specification)

Operation Definition

{
  "resourceType" : "OperationDefinition",
  "id" : "StructureDefinition-questionnaire",
  "text" : {
    "status" : "generated",
    "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p class=\"res-header-id\"><b>Generated Narrative: OperationDefinition StructureDefinition-questionnaire</b></p><a name=\"StructureDefinition-questionnaire\"> </a><a name=\"hcStructureDefinition-questionnaire\"> </a><a name=\"StructureDefinition-questionnaire-en-US\"> </a><p>URL: [base]/StructureDefinition/$questionnaire</p><p>URL: [base]/StructureDefinition/[id]/$questionnaire</p><h3>Parameters</h3><table class=\"grid\"><tr><td><b>Use</b></td><td><b>Name</b></td><td><b>Scope</b></td><td><b>Cardinality</b></td><td><b>Type</b></td><td><b>Binding</b></td><td><b>Documentation</b></td></tr><tr><td>IN</td><td>identifier</td><td/><td>0..1</td><td><a href=\"datatypes.html#Identifier\">Identifier</a></td><td/><td><div><p>A logical identifier (i.e. 'StructureDefinition.identifier''). The server must know the StructureDefinition or be able to retrieve it from other known repositories.</p>\n</div></td></tr><tr><td>IN</td><td>profile</td><td/><td>0..1</td><td><a href=\"structuredefinition.html\">StructureDefinition</a></td><td/><td><div><p>The <a href=\"structuredefinition.html\">StructureDefinition</a> is provided directly as part of the request. Servers may choose not to accept profiles in this fashion</p>\n</div></td></tr><tr><td>IN</td><td>url</td><td>type</td><td>0..1</td><td><a href=\"datatypes.html#canonical\">canonical</a> (<a href=\"structuredefinition.html\" title=\"http://hl7.org/fhir/StructureDefinition/StructureDefinition\">StructureDefinition</a>)</td><td/><td><div><p>The StructureDefinition's official URL (i.e. 'StructureDefinition.url'). The server must know the StructureDefinition or be able to retrieve it from other known repositories.</p>\n</div></td></tr><tr><td>IN</td><td>supportedOnly</td><td/><td>0..1</td><td><a href=\"datatypes.html#boolean\">boolean</a></td><td/><td><div><p>If true, the questionnaire will only include those elements marked as &quot;mustSupport='true'&quot; in the StructureDefinition.</p>\n</div></td></tr><tr><td>OUT</td><td>return</td><td/><td>1..1</td><td><a href=\"questionnaire.html\">Questionnaire</a></td><td/><td><div><p>The questionnaire form generated based on the StructureDefinition.</p>\n</div></td></tr></table><div><p><strong>Open Issue</strong>: Ideally, extensions should be populated in the generated <a href=\"questionnaire.html\">Questionnaire</a> that will support taking <a href=\"questionnaireresponse.html\">QuestionnaireResponse</a> resources generated from the Questionnaire and turning them back into the appropriate resources.</p>\n</div></div>"
  },
  "extension" : [{
    "url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm",
    "valueInteger" : 5
  },
  {
    "url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
    "valueCode" : "trial-use"
  },
  {
    "url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
    "valueCode" : "fhir"
  }],
  "url" : "http://hl7.org/fhir/OperationDefinition/StructureDefinition-questionnaire",
  "version" : "6.0.0-ballot2",
  "name" : "Questionnaire",
  "title" : "Build Questionnaire",
  "status" : "draft",
  "kind" : "operation",
  "experimental" : false,
  "date" : "2024-11-20T17:09:41+00:00",
  "publisher" : "HL7 International / FHIR Infrastructure",
  "contact" : [{
    "telecom" : [{
      "system" : "url",
      "value" : "http://hl7.org/fhir"
    },
    {
      "system" : "email",
      "value" : "fhir@lists.hl7.org"
    }]
  },
  {
    "telecom" : [{
      "system" : "url",
      "value" : "http://www.hl7.org/Special/committees/fiwg"
    }]
  }],
  "description" : "Generates a [Questionnaire](questionnaire.html) instance  based on a specified [StructureDefinition](structuredefinition.html), creating questions for each core element or extension element found in the [StructureDefinition](structuredefinition.html).    \n\nIf the operation is not called at the instance level, one of the *identifier*, *profile* or *url* 'in' parameters must be provided. If more than one is specified, servers may raise an error or may resolve with the parameter of their choice. If called at the instance level, these parameters will be ignored. The response will contain a [Questionnaire](questionnaire.html) instance based on the specified [StructureDefinition](structuredefinition.html) and/or an [OperationOutcome](operationoutcome.html) resource with errors or warnings.  Nested groups are used to handle complex structures and data types.  If the 'supportedOnly' parameter is set to true, only those elements marked as \"must support\" will be included.  \n\nThis operation is intended to enable auto-generation of simple interfaces for arbitrary profiles.  The 'questionnaire' approach to data entry has limitations that will make it less optimal than custom-defined interfaces.  However, this function may be useful for simple applications or for systems that wish to support \"non-core\" resources with minimal development effort.",
  "jurisdiction" : [{
    "coding" : [{
      "system" : "http://unstats.un.org/unsd/methods/m49/m49.htm",
      "code" : "001",
      "display" : "World"
    }]
  }],
  "affectsState" : false,
  "code" : "questionnaire",
  "comment" : "**Open Issue**: Ideally, extensions should be populated in the generated [Questionnaire](questionnaire.html) that will support taking [QuestionnaireResponse](questionnaireresponse.html) resources generated from the Questionnaire and turning them back into the appropriate resources.",
  "resource" : ["StructureDefinition"],
  "system" : false,
  "type" : true,
  "instance" : true,
  "parameter" : [{
    "name" : "identifier",
    "use" : "in",
    "min" : 0,
    "max" : "1",
    "documentation" : "A logical identifier (i.e. 'StructureDefinition.identifier''). The server must know the StructureDefinition or be able to retrieve it from other known repositories.",
    "type" : "Identifier"
  },
  {
    "name" : "profile",
    "use" : "in",
    "min" : 0,
    "max" : "1",
    "documentation" : "The [StructureDefinition](structuredefinition.html) is provided directly as part of the request. Servers may choose not to accept profiles in this fashion",
    "type" : "StructureDefinition"
  },
  {
    "name" : "url",
    "use" : "in",
    "scope" : ["type"],
    "min" : 0,
    "max" : "1",
    "documentation" : "The StructureDefinition's official URL (i.e. 'StructureDefinition.url'). The server must know the StructureDefinition or be able to retrieve it from other known repositories.",
    "type" : "canonical",
    "targetProfile" : ["http://hl7.org/fhir/StructureDefinition/StructureDefinition"]
  },
  {
    "name" : "supportedOnly",
    "use" : "in",
    "min" : 0,
    "max" : "1",
    "documentation" : "If true, the questionnaire will only include those elements marked as \"mustSupport='true'\" in the StructureDefinition.",
    "type" : "boolean"
  },
  {
    "name" : "return",
    "use" : "out",
    "min" : 1,
    "max" : "1",
    "documentation" : "The questionnaire form generated based on the StructureDefinition.",
    "type" : "Questionnaire"
  }]
}

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