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:

20.3.1 Command "DownloadAndOpenStudy"

The samples of configuration files and HTTP RPC service test pages are available in the HTTP_RPC_test_pages archive at: https://inobitec.com/downloads/dicomviewer/.

To execute the DownloadAndOpenStudy command using the C-GET or C-MOVE methods:

  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 HTTP_RPC_test_pages folder).

Specify the following parameters in the downloadAndOpenStudy.xml file:

If the DICOM Listener... (see Section 13.1.1) is disabled, data from the PACS Server can only be downloaded via C-GET. In this case, the SCU "CLIENT" value is transferred to the PACS Server by default.

The samples of HTTP RPC service configuration files are given in Section 20.3.3.

To execute the DownloadAndOpenStudy command via WADO Web service, proceed as follows:

  1. In the DICOM Viewer, switch on the HIS/HTTP service by selecting the Services option on the Network menu (for details, see Section 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 HTTP_RPC_test_pages folder).

The following additional parameters are provided in the downloadAndOpenStudy.xml file:

To execute the DownloadAndOpenStudy command via the WADO Web Service, the CommandType parameter must have the WADO-RS value.

The samples of HTTP RPC service configuration files are given in Section 20.3.3.

The list of UID studies to be loaded is transferred within the StudyInstanceUID parameter value of the HTTP RPC request. The list of study registration numbers is transferred within the AccessionNumber parameter value of the HTTP RPC request. In both cases, the lists of parameters are transferred in the same way as they are transferred in the command line (see Section 20.1).

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.

The list of StudyInstanceUID and AccessionNumber parameters is composed as follows: the first StudyInstanceUID parameter value is matched by the first AccessionNumber parameter value, the second StudyInstanceUID parameter value is matched by the second AccessionNumber parameter value, etc.

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 HTTP_RPC_test_pages 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:

  4. Click the "Send command" button.

20.3.2 Command "DisplayStudy"

The samples of configuration files and HTTP RPC service test pages are available in the HTTP_RPC_test_pages archive at: https://inobitec.com/downloads/dicomviewer/.

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 HTTP_RPC_test_pages folder).

Specify the following parameters in the displayStudy.xml file:

Also you can use the display.bat test script from the HTTP_RPC_test_pages 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:

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

The samples of HTTP RPC service configuration files are given in Section 20.3.3.

The list of UID studies to be loaded is transferred within the StudyInstanceUID parameter value of the HTTP RPC request. The list of parameters is transferred in the same way as it is transferred in the command line (see Section 20.1).

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" for the C-MOVE method

<?xml version=";1.0"; encoding=";utf-8";?>
<methodCall>
  <methodName>DownloadAndOpenStudy</methodName>
  <params>
    <param>
      <value>
        <struct>
          <member>
            <name>PatientID</name>
            <value>
              <string>
              8211038be1bebb57fb131414a04818f4f5c8f25f4a02cccec2b0cc20
              \...\8211038be1bebb57fb131414a04818f4f5c8f25f4a02cccec2b0cc21
              </string>
            </value>
          </member>
          <member>
            <name>StudyInstanceUID</name>
              <value>
                <string>
                1.2.276.0.7230010.3.1.2.1658924591.30288.1727881038.636
                \...\1.2.276.0.7230010.3.1.2.1658924591.30288.1727881038.637
                </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>

"downloadAndOpenStudy.xml" downloading data from the PACS server via WADO service

<?xml version=";1.0"; encoding=";utf-8";?>
<methodCall>
  <methodName>DownloadAndOpenStudy</methodName>
  <params>
    <param>
      <value>
        <struct>
          <member>
            <name>PatientID</name>
            <value>
              <string>
              8211038be1bebb57fb131414a04818f4f5c8f25f4a02cccec2b0cc20
              \...\8211038be1bebb57fb131414a04818f4f5c8f25f4a02cccec2b0cc21
              </string>
            </value>
          </member>
          <member>
            <name>StudyInstanceUID</name>
              <value>
                <string>
                1.2.276.0.7230010.3.1.2.1658924591.30288.1727881038.636
                \...\1.2.276.0.7230010.3.1.2.1658924591.30288.1727881038.637
                </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>WadoServiceRootPath</name>
              <value>
                <string>path/to/service</string>
              </value>
          </member>
          <member>
            <name>IsWadoSecured</name>
              <value>
                <string>false</string>
              </value>
          </member>
          <member>
            <name>WadoPort</name>
              <value>
                <string>8010</string>
              </value>
          </member>
          <member>
            <name>WadoAuthLogin</name>
              <value>
                <string></string>
              </value>
          </member>
          <member>
            <name>WadoAuthPassword</name>
              <value>
                <string></string>
              </value>
          </member>
          <member>
            <name>CommandType</name>
              <value>
                <string>WADO-RS</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>
              8211038be1bebb57fb131414a04818f4f5c8f25f4a02cccec2b0cc20
              \...\8211038be1bebb57fb131414a04818f4f5c8f25f4a02cccec2b0cc21
              </string>
            </value>
          </member>
          <member>
            <name>StudyInstanceUID</name>
              <value>
                <string>
                1.2.276.0.7230010.3.1.2.1658924591.30288.1727881038.636
                \...\1.2.276.0.7230010.3.1.2.1658924591.30288.1727881038.637
                </string>
              </value>
          </member>
        </struct>
      </value>
    </param>
  </params>
</methodCall>