Annex E – WADO WS Schemas and Examples

E.1 WADO WS XSD SCHEMA (INFORMATIVE)

THE FOLLOWING XSD SCHEMA CAN BE USED FOR THE WADO WS IMPLEMENTATION:

<?xml version="1.0" encoding="UTF-8"?>

<xs:schema xmlns="urn:ihe:rad:xdsi-b:2009" xmlns:xs="http://www.w3.org/2001/XMLSchema";

targetNamespace="urn:ihe:rad:xdsi-b:2009" elementFormDefault="qualified"

attributeFormDefault="unqualified" xmlns:tns="urn:oasis:names:tc:ebxml-regrep:xsd:rs:3.0">

<xs:import namespace="urn:oasis:names:tc:ebxml-regrep:xsd:rs:3.0"/>

<xs:import namespace="urn:ihe:iti:xds-b:2007"/>

<xs:simpleType name="LongName">

<xs:restriction base="xs:string">

<xs:maxLength value="256"/>

</xs:restriction>

</xs:simpleType>

<xs:complexType name="RetrieveDocumentSetRequestType">

<xs:sequence>

<xs:element name="DocumentRequest" maxOccurs="unbounded">

<xs:complexType>

<xs:sequence>

<xs:element name="HomeCommunityId" type="LongName" minOccurs="0">

<xs:annotation>

<xs:documentation>This corresponds to the home attribute of the Identifiable class in regrep RIM (regrep-rim-3.0-os.pdf, page 20)</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="RepositoryUniqueId" type="LongName" minOccurs="0">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.repositoryUniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="DocumentUniqueId" type="LongName">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.uniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:complexType>

<xs:complexType name="RegistryErrorType">

<xs:simpleContent>

<xs:extension base="xs:string">

<xs:attribute name="codeContext" type="xs:string" use="required"/>

<xs:attribute name="errorCode" type="xs:string" use="required"/>

<xs:attribute default="urn:oasis:names:tc:ebxml-regrep:ErrorSeverityType:Error"

name="severity" type="xs:anyURI"/>

<xs:attribute name="location" type="xs:string" use="optional"/>

</xs:extension>

</xs:simpleContent>

</xs:complexType>

<xs:complexType name="RegistryErrorListType">

<xs:annotation>

<xs:documentation xml:lang="en">The RegistryErrorList is derived from the ErrorList element from the ebXML Message Service Specification</xs:documentation>

</xs:annotation>

<xs:sequence>

<xs:element maxOccurs="unbounded" name="RegistryError" type="RegistryErrorType"/>

</xs:sequence>

<xs:attribute name="highestSeverity" type="xs:anyURI" use="optional"/>

</xs:complexType>

<xs:complexType name="RegistryResponseType">

<xs:annotation>

<xs:documentation xml:lang="en">Base type for all ebXML Registry responses</xs:documentation>

</xs:annotation>

<xs:sequence>

<!-- every response may be extended using Slots. -->

<xs:element minOccurs="0" type="RegistryErrorListType" name="RegistryErrorList"/>

</xs:sequence>

<xs:attribute name="status" type="xs:anyURI" use="required"/>

<!-- id is the request if for the request for which this is a response -->

<xs:attribute name="requestId" type="xs:anyURI" use="optional"/>

</xs:complexType>

<xs:element name="RetrieveDocumentSetRequest" type="RetrieveDocumentSetRequestType"/>

<xs:complexType name="RetrieveDocumentSetResponseType">

<xs:sequence>

<xs:element name="RegistryResponse" type="RegistryResponseType"/>

<xs:sequence minOccurs="0">

<xs:element maxOccurs="unbounded" name="DocumentResponse">

<xs:complexType>

<xs:sequence>

<xs:element minOccurs="0" name="HomeCommunityId" type="LongName">

<xs:annotation>

<xs:documentation>This corresponds to the home attribute of the Identifiable class in regrep RIM (regrep-rim-3.0-os.pdf, page 20)</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="RepositoryUniqueId" type="LongName">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.repositoryUniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="DocumentUniqueId" type="LongName">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.uniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element minOccurs="0" name="Document" type="xs:base64Binary"/>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:sequence>

</xs:complexType>

<xs:element name="RetrieveDocumentSetResponse" type="RetrieveDocumentSetResponseType"/>

<xs:complexType name="RetrieveRenderedImagingDocumentSetRequestType">

<xs:sequence>

<xs:element maxOccurs="unbounded" name="StudyRequest">

<xs:complexType>

<xs:sequence>

<xs:element maxOccurs="unbounded" name="SeriesRequest">

<xs:complexType>

<xs:sequence>

<xs:element maxOccurs="unbounded" name="RenderedDocumentRequest">

<xs:complexType>

<xs:sequence>

<xs:element name="HomeCommunityId" type="LongName"

minOccurs="0">

<xs:annotation>

<xs:documentation>This corresponds to the home attribute of the Identifiable class in regrep RIM (regrep-rim-3.0-os.pdf, page 20)</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="RepositoryUniqueId"

type="LongName" minOccurs="0">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.repositoryUniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="DocumentUniqueId" type="LongName">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.uniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element minOccurs="0" name="Annotation"

type="xs:string"/>

<xs:element minOccurs="0" name="Rows"

type="xs:string"/>

<xs:element minOccurs="0" name="Columns"

type="xs:string"/>

<xs:element minOccurs="0" name="Region"

type="xs:string"/>

<xs:element minOccurs="0" name="WindowWidth"

type="xs:string"/>

<xs:element minOccurs="0" name="WindowCenter"

type="xs:string"/>

<xs:element minOccurs="0" name="ImageQuality"

type="xs:string"/>

<xs:element minOccurs="0"

name="PresentationSeriesUID" type="xs:string"/>

<xs:element minOccurs="0" name="Anonymize"

type="xs:string"/>

<xs:element minOccurs="0" name="FrameNumber"

type="xs:string"/>

<xs:element minOccurs="1" name="ContentTypeList"

type="xs:string" maxOccurs="unbounded"/>

<xs:element minOccurs="1" name="CharsetList"

type="xs:string" maxOccurs="unbounded"/>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:complexType>

<xs:element name="RetrieveRenderedImagingDocumentSetRequest"

type="RetrieveRenderedImagingDocumentSetRequestType"/>

<xs:complexType name="RetrieveRenderedImagingDocumentSetResponseType">

<xs:sequence>

<xs:element name="RegistryResponse" type="RegistryResponseType"/>

<xs:element maxOccurs="unbounded" name="RenderedDocumentSetResponse" minOccurs="0">

<xs:complexType>

<xs:sequence>

<xs:element name="HomeCommunityId" type="LongName" minOccurs="0">

<xs:annotation>

<xs:documentation>This corresponds to the home attribute of the Identifiable class in regrep RIM (regrep-rim-3.0-os.pdf, page 20)</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="RepositoryUniqueId" type="LongName" minOccurs="1">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.repositoryUniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="SourceDocumentUniqueId" type="LongName">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.uniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element minOccurs="1" name="Annotation" type="xs:string"/>

<xs:element minOccurs="1" name="Rows" type="xs:string"/>

<xs:element minOccurs="1" name="Columns" type="xs:string"/>

<xs:element minOccurs="1" name="Region" type="xs:string"/>

<xs:element name="WindowWidth" type="xs:string"/>

<xs:element minOccurs="1" name="WindowCenter" type="xs:string"/>

<xs:element minOccurs="1" name="ImageQuality" type="xs:string"/>

<xs:element minOccurs="1" name="PresentationSeriesUID" type="xs:string"/>

<xs:element minOccurs="0" name="Anonymize" type="xs:string"/>

<xs:element minOccurs="0" name="FrameNumber" type="xs:string"/>

<xs:element minOccurs="1" name="mimeType" type="xs:string" maxOccurs="1"/>

<xs:element minOccurs="1" name="Document" type="xs:base64Binary"/>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:complexType>

<xs:element name="RetrieveRenderedImagingDocumentSetResponse"

type="RetrieveRenderedImagingDocumentSetResponseType"/>

<xs:complexType name="RetrieveImagingDocumentSetInformationRequestType">

<xs:sequence>

<xs:element maxOccurs="unbounded" name="StudyRequest">

<xs:complexType>

<xs:sequence>

<xs:element maxOccurs="unbounded" name="SeriesRequest">

<xs:complexType>

<xs:sequence>

<xs:element maxOccurs="unbounded"

name="DocumentInformationRequest">

<xs:complexType>

<xs:sequence>

<xs:element name="HomeCommunityId" type="LongName"

minOccurs="0">

<xs:annotation>

<xs:documentation>This corresponds to the home attribute of the Identifiable class in regrep RIM (regrep-rim-3.0-os.pdf, page 20)</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="RepositoryUniqueId"

type="LongName" minOccurs="1">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.repositoryUniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="DocumentUniqueId" type="LongName">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.uniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element minOccurs="0" name="Anonymize"

type="xs:string"/>

<xs:element minOccurs="1" name="XPath"

type="xs:string" maxOccurs="1"/>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:complexType>

<xs:element name="RetrieveImagingDocumentSetInformationRequest"

type="RetrieveImagingDocumentSetInformationRequestType"/>

<xs:complexType name="RetrieveImagingDocumentSetInformationResponseType">

<xs:sequence>

<xs:element name="RegistryResponse" type="RegistryResponseType"/>

<xs:element maxOccurs="unbounded" name="DocumentInformationResponse" minOccurs="0">

<xs:complexType>

<xs:sequence>

<xs:element name="HomeCommunityId" type="LongName" minOccurs="0">

<xs:annotation>

<xs:documentation>This corresponds to the home attribute of the Identifiable class in regrep RIM (regrep-rim-3.0-os.pdf, page 20)</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="RepositoryUniqueId" type="LongName" minOccurs="1">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.repositoryUniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element name="DocumentUniqueId" type="LongName">

<xs:annotation>

<xs:documentation>This is the XDSDocumentEntry.uniqueId attribute in the XDS metadata</xs:documentation>

</xs:annotation>

</xs:element>

<xs:element minOccurs="0" name="FrameNumber" type="xs:string"/>

<xs:element minOccurs="1" name="XPathResponseList">

<xs:complexType>

<xs:sequence>

<xs:element maxOccurs="unbounded" name="XPathResponse"

type="xs:string"/>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:sequence>

</xs:complexType>

<xs:element name="RetrieveImagingDocumentSetInformationResponse"

type="RetrieveImagingDocumentSetInformationResponseType"/>

</xs:schema>

E.4 WADO WS REQUEST EXAMPLE (informative)

Example of requesting the retrieval of images from a series in JPEG resized to 300 pixels max with associated information on modality and instance number. Note that the multipart related MTOM/XOP encoding is used in the request as well as response as required by the Web Services standards.

POST /tf6/services/xdsrepositoryb HTTP/1.1

Content-Type: multipart/related; boundary=MIMEBoundaryurn_uuid_DCD262C64C22DB97351256303951323; type="application/xop+xml"; start="<0.urn:uuid:DCD262C64C22DB97351256303951324@apache.org>"; start-info="application/soap+xml"; action="urn:dicom:ws:wado:2011:RetrieveRenderedImagingDocumentSet"

User-Agent: Axis2

Host: localhost:5000

--MIMEBoundaryurn_uuid_DCD262C64C22DB97351256303951323

Content-Type: application/xop+xml; charset=UTF-8; type="application/soap+xml"

Content-Transfer-Encoding: binary

Content-ID: <0.urn:uuid:DCD262C64C22DB97351256303951324@apache.org>

<s:Envelope

xmlns:s="http://www.w3.org/2003/05/soap-envelope";

xmlns:a="http://www.w3.org/2005/08/addressing">;

<s:Header>

<a:Action s:mustUnderstand="1">urn:dicom:ws:wado:2011:RetrieveRenderedImagingDocumentSet </a:Action>

<a:MessageID>urn:uuid:0fbfdced-6c01-4d09-a110-2201afedaa02</a:MessageID>

<a:ReplyTo s:mustUnderstand="1">

<a:Address>http://www.w3.org/2005/08/addressing/anonymous</a:Address>

</a:ReplyTo>

<a:To >http://localhost:2647/XdsService/DocSource.svc</a:To>

</s:Header>

<s:Body>

<RetrieveImagingDocumentSetRequest xmlns:iherad="urn:ihe:rad:xdsi-b:2009" xmlns:ihe="urn:ihe:iti:xds-b:2007">

<StudyRequest studyInstanceUID="1.3.6.1.4...101">

<SeriesRequest seriesInstanceUID="1.3.6.1.4...201">

<ihe:DocumentRequest>

<ihe:RepositoryUniqueId>1.3.6.1.4...1000</ihe:RepositoryUniqueId>

<ihe:DocumentUniqueId>1.3.6.1.4...2300</ihe:DocumentUniqueId>

<Rows>300</Rows>

<Columns>300</Columns>

<ContentTypeList>

<ContentType>image/jpeg</ContentType>

</ContentTypeList>

</ihe:DocumentRequest>

<ihe:DocumentRequest>

<ihe:RepositoryUniqueId>1.3.6.1.4...1000</ihe:RepositoryUniqueId>

<ihe:DocumentUniqueId>1.3.6.1.4...2301</ihe:DocumentUniqueId>

<Rows>300</Rows>

<Columns>300</Columns>

<ContentTypeList>

<ContentType>image/jpeg</ContentType>

</ContentTypeList>

</ihe:DocumentRequest>

</SeriesRequest>

</StudyRequest>

</RetrieveRenderedImagingDocumentSetRequest>

</s:Body>

</s:Envelope>

--MIMEBoundaryurn_uuid_DCD262C64C22DB97351256303951323—

E.5 WADO WS RESPONSE EXAMPLE

Example of the response corresponding to the above request:

HTTP/1.1 200 OK

Server: Apache-Coyote/1.1

Content-Type: multipart/related; boundary=MIMEBoundaryurn_uuid_F862C3E04D9E35266C1256303956115; type="application/xop+xml"; start="0.urn:uuid:F862C3E04D9E35266C1256303956116@apache.org"; start-info="application/soap+xml"; action="urn:ihe:iti:2007:RetrieveDocumentSetResponse"

Date: Fri, 23 Oct 2009 13:19:11 GMT

--MIMEBoundaryurn_uuid_F862C3E04D9E35266C1256303956115

Content-Type: application/xop+xml; charset=UTF-8; type="application/soap+xml"

Content-Transfer-Encoding: binary

Content-ID: <0.urn:uuid:F862C3E04D9E35266C1256303956116@apache.org>

<s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope"; xmlns:a="http://www.w3.org/2005/08/addressing">;

<s:Header>

<a:Action s:mustUnderstand="1">urn:ihe:iti:2007:RetrieveRenderedImagingDocumentSetResponse</a:Action>

<a:RelatesTo>urn:uuid:0fbfdced-6c01-4d09-a110-2201afedaa02</a:RelatesTo>

</s:Header>

<s:Body>

<RetrieveDocumentSetResponse

xmlns="urn:ihe:iti:xds-b:2007"

xmlns:lcm="urn:oasis:names:tc:ebxml-regrep:xsd:lcm:3.0"

xmlns:query="urn:oasis:names:tc:ebxml-regrep:xsd:query:3.0"

xmlns:rim="urn:oasis:names:tc:ebxml-regrep:xsd:rim:3.0"

xmlns:rs="urn:oasis:names:tc:ebxml-regrep:xsd:rs:3.0">

<rs:RegistryResponse status="urn:oasis:names:tc:ebxml-regrep:ResponseStatusType:Success"/>

<DocumentResponse>

<ihe:RepositoryUniqueId>1.3.6.1.4...1000</ihe:RepositoryUniqueId>

<SourceDocumentUniqueId>1.3.6.1.4...2300</SourceDocumentUniqueId>

<Annotation>patient</Annotation>

<Rows>300</Rows>

<Columns>300</Columns>

<Region>

<Xmin>0.0</Xmin>

<Ymin>0.0</Ymin>

<Xmax>1.0</Xmax>

<Ymax>1.0<Ymax>

</Region>

<WindowCenter>2000</WindowCenter>

<WindowWidth>4096</WindowWidth>

<ImageQuality>30</ImageQuality>

<mimeType>image/jpeg</mimeType>

<Document>

<xop:Include href="cid:1.urn:uuid:F862C3E04D9E35266C1256303956117@apache.org"

xmlns:xop="http://www.w3.org/2004/08/xop/include"/>;

</Document>

</DocumentResponse>

<DocumentResponse>

<RepositoryUniqueId>1.3.6.1.4...1000</RepositoryUniqueId>

<DocumentUniqueId>1.3.6.1.4...2301</DocumentUniqueId>

<Annotation>patient</Annotation>

<Rows>300</Rows>

<Columns>250</Columns>

<Region>

<Xmin>0.0</Xmin>

<Ymin>0.0</Ymin>

<Xmax>1.0</Xmax>

<Ymax>1.0<Ymax>

</Region>

<WindowCenter>2000</WindowCenter>

<WindowWidth>4096</WindowWidth>

<ImageQuality>30</ImageQuality>

<mimeType>image/jpeg</mimeType>

<Document>

<xop:Include href="cid:2.urn:uuid:F862C3E04D9E35266C1256303956117@apache.org"

xmlns:xop="http://www.w3.org/2004/08/xop/include"/>;

</Document>

</DocumentResponse>

</RetrieveDocumentSetResponse>

</s:Body>

</s:Envelope>

--MIMEBoundaryurn_uuid_F862C3E04D9E35266C1256303956115

Content-Type: application/octet-stream

Content-Transfer-Encoding: binary

Content-ID: <1.urn:uuid:F862C3E04D9E35266C1256303956117@apache.org>

This is the binary JPEG payload for the first image.

--MIMEBoundaryurn_uuid_F862C3E04D9E35266C1256303956115

Content-Type: application/octet-stream

Content-Transfer-Encoding: binary

Content-ID: <2.urn:uuid:F862C3E04D9E35266C1256303956117@apache.org>

This is the binary JPEG payload for the second image.

--MIMEBoundaryurn_uuid_F862C3E04D9E35266C1256303956115—