WSDL <message> Element is used to describe the data that is exchanged between the Web Service providers and the consumers. There are two messages per Web Service input and output. The input describes parameters for the web service and the output describes the return data from the Web Service.
WSDL <message> Element contains one or more than one WSDL <part> Element element. Each part parameter has a concrete type associated with it that is specified in the type container element.
Syntax:
<message name = "...">
<part/>
</message>
The below examples will illustrate the WSDL <message> Element:
Example 1: In this example, we will define one message element that will represent a request message AccessRequest. AccessRequest message contains one part, a zip code of type xsd:string. The client request thus provides a zip code to the server.
HTML
<message name = "AccessRequest">
<part name = "zipcode" type = "xsd:string"/>
</message>
We have defined a message element named "AcessRequest" which tells us a request message. The "AccessRequest" message contains one part named "zipcode" of type "xsd:string." This part signifies that the client request provides a zip code as input to the server.
Example 2: In this example, we will define two message elements that will represent a request message AccessRequest, and a response message AccessResponse.
HTML
<message name = "AccessRequest">
<part name = "zipcode" type = "xsd:string"/>
</message>
<message name = "AccessResponse">
<part name = "zipcode" type = "xsd:string"/>
</message>
In this second example, we define two message elements: "AccessRequest" and "AccessResponse." The "AccessRequest" message is for request data, and the "AccessResponse" message is for response data. Both messages contain a part named "zipcode" of type "xsd:string."
In summary, the WSDL <message> element is essential for describing the structure of data exchanged between web service providers and consumers. It allows you to define the parameters and data elements within a message, ensuring clear communication between the client and the server.
Similar Reads
XSLT <message> Element In XSLT (eXtensible Stylesheet Language Transformations), the '<xsl: message>' element outputs messages during the transformation process. It's a way to communicate information or provide feedback during the transformation. This element contains all the other XSL elements such as <xsl: text
1 min read
WSDL <binding> Element WSDL <binding> Element is used to provide details on how a portType operation will actually be transmitted over the wire. It can be delivered using a variety of protocols, such as HTTP GET, HTTP POST, or SOAP. For the SOAP protocol, the transport is SOAP messages on top of the HTTP protocol, a
3 min read
WSDL Elements WSDL (Web Services Description Language) is an XML-based language that describes web services and their functionalities. It provides a standardized way to define the structure and behavior of web services, making it easier for different applications to communicate with one another over the internet.
2 min read
WSDL <definitions> Element WSDL <definitions> element is the root element of the WSDL document. It binds the entire details of the services that are offered by the web server. In short, it provides each and every detail of the web server in a structured manner. Syntax:<definitions xmlns="http://schemas.xmlsoap.org/ws
3 min read
HTML | DOM onmessage Event The onmessage Event in HTML DOM used when an object has received some message through an event source. The event object for onmessage Event supports the following schemes: data: It contains the actual message present inside it.origin: It contains the URL of the document that invoked the event.lastEv
2 min read
HTML Elements An HTML Element consists of a start tag, content, and an end tag, which together define the element's structure and functionality. Elements are the basic building blocks of a webpage and can represent different types of content, such as text, links, images, or headings.For example, the <p> ele
5 min read