This page is part of the FHIR Specification (v0.5.0: DSTU 2 Ballot 2). The current version which supercedes this version is 5.0.0. For a full list of available versions, see the Directory of published versions . Page versions: R5 R4B R4 R3 R2
This resource maintained by the FHIR Management Group Work Group
A Search Parameter that defines a named search item that can be used to search/filter on a resource.
Implementers should be familiar with with the background and concepts described in Profiling FHIR before working with this resource.
Structure
Name | Flags | Card. | Type | Description & Constraints |
---|---|---|---|---|
SearchParameter | DomainResource | Search Parameter for a resource | ||
url | 1..1 | uri | Literal URL used to reference this search parameter | |
name | Σ | 1..1 | string | Name of search parameter |
publisher | Σ | 0..1 | string | Name of the publisher (Organization or individual) |
contact | Σ | 0..* | Element | Contact details of the publisher |
name | Σ | 0..1 | string | Name of a individual to contact |
telecom | Σ | 0..* | ContactPoint | Contact details for individual or publisher |
requirements | 0..1 | string | Why this search parameter is defined | |
status | ?! Σ | 0..1 | code | draft | active | retired ConformanceResourceStatus (Required) |
experimental | Σ | 0..1 | boolean | If for testing purposes, not real usage |
date | Σ | 0..1 | dateTime | Publication Date(/time) |
base | 1..1 | code | The resource type this search parameter applies to ResourceType (Required) | |
type | 1..1 | code | number | date | string | token | reference | composite | quantity | uri SearchParamType (Required) | |
description | 1..1 | string | Documentation for search parameter | |
xpath | 0..1 | string | XPath that extracts the values | |
target | 0..* | code | Types of resource (if a resource reference) ResourceType (Required) |
UML Diagram
XML Template
<SearchParameter xmlns="http://hl7.org/fhir"> <!-- from Resource: id, meta, implicitRules, and language --> <!-- from DomainResource: text, contained, extension, and modifierExtension --> <url value="[uri]"/><!-- 1..1 Literal URL used to reference this search parameter --> <name value="[string]"/><!-- 1..1 Name of search parameter --> <publisher value="[string]"/><!-- 0..1 Name of the publisher (Organization or individual) --> <contact> <!-- 0..* Contact details of the publisher --> <name value="[string]"/><!-- 0..1 Name of a individual to contact --> <telecom><!-- 0..* ContactPoint Contact details for individual or publisher --></telecom> </contact> <requirements value="[string]"/><!-- 0..1 Why this search parameter is defined --> <status value="[code]"/><!-- 0..1 draft | active | retired --> <experimental value="[boolean]"/><!-- 0..1 If for testing purposes, not real usage --> <date value="[dateTime]"/><!-- 0..1 Publication Date(/time) --> <base value="[code]"/><!-- 1..1 The resource type this search parameter applies to --> <type value="[code]"/><!-- 1..1 number | date | string | token | reference | composite | quantity | uri --> <description value="[string]"/><!-- 1..1 Documentation for search parameter --> <xpath value="[string]"/><!-- 0..1 XPath that extracts the values --> <target value="[code]"/><!-- 0..* Types of resource (if a resource reference) --> </SearchParameter>
JSON Template
{ "resourceType" : "SearchParameter", // from Resource: id, meta, implicitRules, and language // from DomainResource: text, contained, extension, and modifierExtension "url" : "<uri>", // R! Literal URL used to reference this search parameter "name" : "<string>", // R! Name of search parameter "publisher" : "<string>", // Name of the publisher (Organization or individual) "contact" : [{ // Contact details of the publisher "name" : "<string>", // Name of a individual to contact "telecom" : [{ ContactPoint }] // Contact details for individual or publisher }], "requirements" : "<string>", // Why this search parameter is defined "status" : "<code>", // draft | active | retired "experimental" : <boolean>, // If for testing purposes, not real usage "date" : "<dateTime>", // Publication Date(/time) "base" : "<code>", // R! The resource type this search parameter applies to "type" : "<code>", // R! number | date | string | token | reference | composite | quantity | uri "description" : "<string>", // R! Documentation for search parameter "xpath" : "<string>", // XPath that extracts the values "target" : ["<code>"] // Types of resource (if a resource reference) }
Structure
Name | Flags | Card. | Type | Description & Constraints |
---|---|---|---|---|
SearchParameter | DomainResource | Search Parameter for a resource | ||
url | 1..1 | uri | Literal URL used to reference this search parameter | |
name | Σ | 1..1 | string | Name of search parameter |
publisher | Σ | 0..1 | string | Name of the publisher (Organization or individual) |
contact | Σ | 0..* | Element | Contact details of the publisher |
name | Σ | 0..1 | string | Name of a individual to contact |
telecom | Σ | 0..* | ContactPoint | Contact details for individual or publisher |
requirements | 0..1 | string | Why this search parameter is defined | |
status | ?! Σ | 0..1 | code | draft | active | retired ConformanceResourceStatus (Required) |
experimental | Σ | 0..1 | boolean | If for testing purposes, not real usage |
date | Σ | 0..1 | dateTime | Publication Date(/time) |
base | 1..1 | code | The resource type this search parameter applies to ResourceType (Required) | |
type | 1..1 | code | number | date | string | token | reference | composite | quantity | uri SearchParamType (Required) | |
description | 1..1 | string | Documentation for search parameter | |
xpath | 0..1 | string | XPath that extracts the values | |
target | 0..* | code | Types of resource (if a resource reference) ResourceType (Required) |
XML Template
<SearchParameter xmlns="http://hl7.org/fhir"> <!-- from Resource: id, meta, implicitRules, and language --> <!-- from DomainResource: text, contained, extension, and modifierExtension --> <url value="[uri]"/><!-- 1..1 Literal URL used to reference this search parameter --> <name value="[string]"/><!-- 1..1 Name of search parameter --> <publisher value="[string]"/><!-- 0..1 Name of the publisher (Organization or individual) --> <contact> <!-- 0..* Contact details of the publisher --> <name value="[string]"/><!-- 0..1 Name of a individual to contact --> <telecom><!-- 0..* ContactPoint Contact details for individual or publisher --></telecom> </contact> <requirements value="[string]"/><!-- 0..1 Why this search parameter is defined --> <status value="[code]"/><!-- 0..1 draft | active | retired --> <experimental value="[boolean]"/><!-- 0..1 If for testing purposes, not real usage --> <date value="[dateTime]"/><!-- 0..1 Publication Date(/time) --> <base value="[code]"/><!-- 1..1 The resource type this search parameter applies to --> <type value="[code]"/><!-- 1..1 number | date | string | token | reference | composite | quantity | uri --> <description value="[string]"/><!-- 1..1 Documentation for search parameter --> <xpath value="[string]"/><!-- 0..1 XPath that extracts the values --> <target value="[code]"/><!-- 0..* Types of resource (if a resource reference) --> </SearchParameter>
JSON Template
{ "resourceType" : "SearchParameter", // from Resource: id, meta, implicitRules, and language // from DomainResource: text, contained, extension, and modifierExtension "url" : "<uri>", // R! Literal URL used to reference this search parameter "name" : "<string>", // R! Name of search parameter "publisher" : "<string>", // Name of the publisher (Organization or individual) "contact" : [{ // Contact details of the publisher "name" : "<string>", // Name of a individual to contact "telecom" : [{ ContactPoint }] // Contact details for individual or publisher }], "requirements" : "<string>", // Why this search parameter is defined "status" : "<code>", // draft | active | retired "experimental" : <boolean>, // If for testing purposes, not real usage "date" : "<dateTime>", // Publication Date(/time) "base" : "<code>", // R! The resource type this search parameter applies to "type" : "<code>", // R! number | date | string | token | reference | composite | quantity | uri "description" : "<string>", // R! Documentation for search parameter "xpath" : "<string>", // XPath that extracts the values "target" : ["<code>"] // Types of resource (if a resource reference) }
Alternate definitions: Schema/Schematron, Resource Profile (XML, JSON)
Path | Definition | Type | Reference |
---|---|---|---|
SearchParameter.status | The lifecycle status of a Value Set or Concept Map | Required | http://hl7.org/fhir/conformance-resource-status |
SearchParameter.base SearchParameter.target | One of the resource types defined as part of FHIR | Required | http://hl7.org/fhir/valueset/resource-types |
SearchParameter.type | Data types allowed to be used for search parameters | Required | http://hl7.org/fhir/search-param-type |
The SearchParameter resource may be used to define searches on extensions. Depending on the context of the extension (as defined in the StructureDefinition), this may require multiple instances of the SearchParameter.xpath element like so:
Search parameters for this resource. The common parameters also apply. See Searching for more information about searching in REST, messaging, and services.
Name | Type | Description | Paths |
base | token | The resource type this search parameter applies to | SearchParameter.base |
description | string | Documentation for search parameter | SearchParameter.description |
name | string | Name of search parameter | SearchParameter.name |
target | token | Types of resource (if a resource reference) | SearchParameter.target |
type | token | number | date | string | token | reference | composite | quantity | uri | SearchParameter.type |
url | uri | Literal URL used to reference this search parameter | SearchParameter.url |