Adobe ColdFusion 8

Passing parameters to a web service

The message and operation elements in the WSDL file contains subelements that define the web service operations and the input and output parameters of each operation, including the data type of each parameter. The following example shows a portion of the WSDL file for the TemperatureService web service:

<message name="getTempRequest">
    <part name="zipcode" type="xsd:string"/>
</message>
<message name="getTempResponse">
    <part name="return" type="xsd:float"/>
</message>
<portType name="TemperaturePortType">
    <operation name="getTemp">
        <input message="tns:getTempRequest"/>
        <output message="tns:getTempResponse"/>
    </operation>
</portType> 

The operation name used in the examples in this section is getTemp. This operation takes a single input parameter defined as a message of type getTempRequest.

You can see that the message element named getTempRequest contains one string parameter: zipcode. When you call the getTemp operation, you pass the parameter as input.