工作组: FHIR Infrastructure  成熟度: 5Trial Use Compartments: N/A

此操作要求服务器检查它是否实现了客户端在其能力声明中提供的所有资源、交互、搜索参数和操作。 客户端可以直接提交能力声明的内容,或者将其能力声明的正式定义URL告知服务器。

The official URL for this operation definition is

 http://hl7.org/fhir/OperationDefinition/CapabilityStatement-implements

Formal Definition (as a OperationDefinition).

URL: [base]/CapabilityStatement/$implements

URL: [base]/CapabilityStatement/[id]/$implements

This is an idempotent operation

In Parameters:
NameCardinalityTypeBindingProfileDocumentation
server0..1canonical

A canonical reference to the server capability statement - use this if the implements is not invoked on an instance (or on the /metadata end-point)

client0..1canonical

A canonical reference to the client capability statement - use this if the implements is not invoked on an instance (or on the /metadata end-point)

resource0..1CapabilityStatement

The client capability statement, provided inline

Out Parameters:
NameCardinalityTypeBindingProfileDocumentation
return1..1OperationOutcome

Outcome of the CapabilityStatement test

Note: as this is the only out parameter, it is a resource, and it has the name 'return', the result of this operation is returned directly as a resource

该操作不会执行完整的符合性检查,更不会检查配置(profiles)的符合性。 它只检查客户端期望使用的动作是否在技术上提供,此操作实现了以下功能:

  • 客户端的能力声明中有的资源,服务器的能力声明中必须有一个条目(entry)用来对应客户端的每个资源。
  • 服务器对资源支持必须具有与updateCreate、conditionalCreate、conditionalRead、conditionalUpdate、conditionalDelete、searchInclude、searchRevInclude匹配的标签。
  • 服务器能力声明中的每个交互必须与客户端能力声明相匹配(无论是否是对资源的交互)
  • 服务器能力声明具有的搜索参数必须能与客户端能力声明的所有搜索参数的名称和定义相匹配。
  • 服务器能力声明具有的操作定义必须能与客户端能力声明的所有操作的引用相匹配。

如果能力声明符合以上这些规则,则返回值为200 OK,返回的操作结果资源中的issue元素的 severity 属性值都不会>=error。 如果能力声明不能匹配,则返回值为4xx 错误,且返回的操作结果资源的issue元素中至少有一个的 severity 属性值>=error。

Request: Request a CapabilityStatement implements comparison between a client and server systems

POST [base]/CapabilityStatement/$implements
[other headers]

<Parameters xmlns="http://hl7.org/fhir">
  <parameter>
    <name value="server"/>
    <valueUri value="http://server.example.org/fhir/metadata"/>
  </parameter>
  <parameter>
    <name value="client"/>
    <valueUri value="http://client.example.org/fhir/metadata"/>
  </parameter>
</Parameters>

Response:

HTTP/1.1 200 OK
[other headers]

<?xml version="1.0" encoding="UTF-8"?>
<OperationOutcome xmlns="http://hl7.org/fhir">
  <id value="implementsok"/>
  <text>
    <status value="additional"/>
    <div xmlns="http://www.w3.org/1999/xhtml">
      <p>Server http://server.example.org/fhir/metadata implements client http://client.example.org/fhir/metadata capabilities.</p>
    </div>
  </text>
  <issue> 
    <severity value="information"/>
    <code value="informational"/>
    <details>
      <text value="Server http://server.example.org/fhir/metadata implements client http://client.example.org/fhir/metadata capabilities."/>
    </details>
 </issue>
</OperationOutcome>

 

For more information about operations, including how they are invoked, see Operations.