• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

Consuming Web Services

In the last section, we walked through the fundamentals of creating Web services. As we discovered, Web service creation in ColdFusion MX is exceptionally easy when we utilize the functionality inherent in ColdFusion components (CFCs). So how do we “consume” a Web service from within ColdFusion? How do we utilize data from other ColdFusion servers or disparate platforms, such as Microsoft .NET and Oracle 9i, running on other networks? As long as these Web services are standards-compliant, we should have no problem using them.

Consult the WSDL

The first step to consuming a Web service is obtaining the URL of the WSDL document for the service you'll be using. To do this, consult a UDDI directory or the Web service provider. The WSDL document contains all the information you will need to call the Web service (methods, parameters, data types, expected return values, and so on). In Listing 24.14, let's take a look at part of the WSDL for our number translation Web service from a previous section.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint