Inobitec DICOM Viewer

20.3. HTTP RPC service

The Inobitec DICOM Viewer provides an HTTP RPC Service that allows you to execute commands. Now two commands are supported:

  • DownloadAndOpenStudy;

  • DisplayStudy.

20.3.1 Command "DownloadAndOpenStudy"

  • DownloadAndOpenStudy — command allows you to download the study from the PACS Server to the Local Storage and then open it. When this command is received, the DICOM Viewer searches the required study in the Local Storage. If the study is in the Local Storage, then the DICOM Viewer opens its first series in flat images view mode. If the required study is not found in the Local Storage, the DICOM Viewer will send a download request to the PACS Server and after the start of the downloading files will open study in the flat images view mode.

To execute the DownloadAndOpenStudy command:

  1. In the DICOM Viewer, switch on the DICOM and HIS/HTTP services by selecting the Services option on the Network menu (for details, see Sections 13.1.1 and 13.1.2).

  2. Send HTTP RPC request to open study by sendind POST request containing xml file in the special format (e.g. downloadAndOpenStudy.xml in the demo folder).

Specify the following parameters in the downloadAndOpenStudy.xml file:

  • PatientID (optional) — ID of the patient whose study should be opened;

  • StudyInstanceUID — UID of the study to be opened;

  • AccessionNumber — Accession Number of the study to be opened;

  • AET — AE Title of the PACS Server;

  • IP — network address of the PACS Server;

  • port — DICOM port of the PACS Server;

  • CommandType (optional) — method to download images from the PACS Server to the DICOM Viewer. The values C-GET (by default) and C-MOVE can be used. If you use the C-MOVE method then the PACS Server must be configured appropriately.

The values of the StudyInstanceUID and AccessionNumber, parameters provided in the xml file must belong to the same study. If the StudyInstanceUID and AccessionNumber parameters do not belong to the same study, you will not be able to download the study.

You may search for and download a study using only the value of the AccessionNumber parameter. To do that, delete the values of thePatientID and StudyInstanceUID parameters from the downloadAndOpenStudy.xml file leaving only the AccessionNumber and the PACS Server parameters (AET, IP, and port).

If the AET, IP, and port values have not been provided, the study will be downloaded from the DICOM Server (PACS) set by default. If only one or two parameters out of three (AET, IP, and port) have been provided, the command is considered invalid.

Also you can use the test page (testpage.html in the demo folder):

  1. In the DICOM Viewer, switch on the DICOM and HIS/HTTP services by selecting the Services option on the Network menu (for details, see Sections 13.1.1 and 13.1.2).

  2. Open the testpage.html file.

  3. Fill in the following fields:

    • AET — AE Title of the PACS Server;

    • IP — network address of the PACS Server;

    • Port — DICOM port of the PACS Server;

    • StudyUID — UID of the study to be opened;

    • Destination IP — network address of the DICOM Viewer;

    • Destination port — HTTP port of the DICOM Viewer.

  4. Click the "Send command" button.

You will find the HTTP RPC service setup instructions, configuration files templates, and test pages at https://inobitec.com/downloads/dicomviewer/.

20.3.2 Command "DisplayStudy"

  • DisplayStudy — command allows you to open study from the Local Storage. When this command is received, the DICOM Viewer searches the required study in the Local Storage. If the study is in the Local Storage, then the DICOM Viewer opens its first series in the flat images view mode. At the moment to obtain this command the study should already be stored in the Local Storage.

To execute DisplayStudy command:

  1. In the DICOM Viewer, switch on the DICOM and HIS/HTTP services by selecting the Services option on the Network menu (for details, see Sections 13.1.1 and 13.1.2).

  2. Send HTTP RPC request to open study by sendind POST request containing xml file in the special format (e.g. displayStudy.xml in the demo folder).

Specify the following parameters in the displayStudy.xml file:

  • PatientID (optional) — ID of the patient whose study should be opened;

  • StudyInstanceUID — UID of the study to be opened.

Also you can use the display.bat test script from the demo folder:

  1. In the DICOM Viewer, switch on the DICOM and HIS/HTTP services by selecting the Services option on the Network menu (for details, see Sections 13.1.1 and 13.1.2).

  2. Specify the following parameters in displayStudy.xml file:

    • PatientID (optional) — ID of the patient whose study should be opened;

    • StudyInstanceUID — UID of the study to be opened.

  3. Execute the script in the comman line with the following parameters:
    display.bat [ip] [port]
    where:

    • ip — network address of the DICOM Viewer;

    • port — HTTP port of the DICOM Viewer.

You will find the HTTP RPC service setup instructions, configuration files templates, and test pages at https://inobitec.com/downloads/dicomviewer/.

20.3.3 Configuration Files of HTTP RPC service

The templates for configuration files of HTTP RPC remote procedure call service are provided below.

"downloadAndOpenStudy.xml"


<?xml version=";1.0"; encoding=";utf-8";?>
<methodCall>
  <methodName>DownloadAndOpenStudy</methodName>
  <params>
    <param>
      <value>
        <struct>
          <member>
            <name>PatientID</name>
            <value>
              <string>9Htqj5c</string>
            </value>
          </member>
          <member>
            <name>StudyInstanceUID</name>
              <value>
                <string>1.2.840.113704.1.111.5600.1107858801.1</string>
              </value>
          </member>
          <member>
            <name>AccessionNumber</name>
              <value>
                <string>value</string>
              </value>
          </member>
          <member>
            <name>AET</name>
              <value>
                <string>PACS_Inobitec</string>
              </value>
          </member>
          <member>
            <name>IP</name>
              <value>
                <string>192.168.0.235</string>
              </value>
          </member>
          <member>
            <name>port</name>
              <value>
                <string>3000</string>
              </value>
          </member>
          <member>
                                                                                            
                                                                                            
            <name>CommandType</name>
              <value>
                <string>C-MOVE</string>
              </value>
          </member>
        </struct>
      </value>
    </param>
  </params>
</methodCall>

"displayStudy.xml"


<?xml version=";1.0"; encoding=";utf-8";?>
<methodCall>
  <methodName>DisplayStudy</methodName>
  <params>
    <param>
      <value>
        <struct>
          <member>
            <name>PatientID</name>
            <value>
              <string>9Htqj5c</string>
            </value>
          </member>
          <member>
            <name>StudyInstanceUID</name>
              <value>
                <string>1.2.840.113704.1.111.5600.1107858801.1</string>
              </value>
          </member>
        </struct>
      </value>
    </param>
  </params>
</methodCall>