SOAP request



  • Hello,
    I am new here and I am trying to SOAP communication using soapUI. I use latest evok, uni pi 1.1 and my point is, how do I know what parameters should I pass as parameters in soap request in soapUI? image


  • administrators

    Device types come from the following list (and otherwise correspond to the device path in the Rest API):

    'relay',
    'input',
    'ai',
    'ao',
    'ee',
    'sensor',
    'i2cbus',
    'adchip',
    'owbus',
    'mcp',
    'gpiobus',
    'pca9685',
    'ds2408',
    'unipi2',
    'uart',
    'neuron',
    'board',
    'misc_output',
    'led',
    'watchdog',
    'register',
    'wifi',
    'light_channel',
    'light_device'
    

    and the "circuit" is the device name as specified in the configuration file.

    As an example for UniPi 1.1:

    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:unip="http://192.168.1.146:8081/UniPiQueryService">
       <soapenv:Header/>
       <soapenv:Body>
          <unip1:SoapQueryInputList xmlns:unip1="http://127.0.1.1:8081/UniPiQueryService">
             <!--1 or more repetitions:-->
             <single_query>
                <device_circuit>1</device_circuit>
                <device_type>relay</device_type>
             </single_query>
          </unip1:SoapQueryInputList>
       </soapenv:Body>
    </soapenv:Envelope>
    

    An example for setting relays:

    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:unip="http://127.0.1.1:8081/UniPiCommandService">
       <soapenv:Header/>
       <soapenv:Body>
          <unip:SoapCommandInputList>
             <!--1 or more repetitions:-->
             <single_command>
                <device_circuit>1</device_circuit>
                <device_type>relay</device_type>
                <!--1 or more repetitions:-->
                <property_item>
                   <property_name>value</property_name>
                   <property_value>"0"</property_value>
                </property_item>
             </single_command>
             <single_command>
                <device_circuit>2</device_circuit>
                <device_type>relay</device_type>
                <!--1 or more repetitions:-->
                <property_item>
                   <property_name>value</property_name>
                   <property_value>"1"</property_value>
                </property_item>
             </single_command>
             <single_command>
                <device_circuit>3</device_circuit>
                <device_type>relay</device_type>
                <!--1 or more repetitions:-->
                <property_item>
                   <property_name>value</property_name>
                   <property_value>"1"</property_value>
                </property_item>
             </single_command>
          </unip:SoapCommandInputList>
       </soapenv:Body>
    </soapenv:Envelope>
    

    We'll try to provide the examples in the documentation in the next EVOK release.


Log in to reply
 

Looks like your connection to UniPi.technology Forum was lost, please wait while we try to reconnect.