Topic
5 replies Latest Post - ‏2013-09-17T15:06:18Z by kolban
SamBPM
SamBPM
7 Posts
ACCEPTED ANSWER

Pinned topic Call WebService published in teamworks

‏2013-09-16T13:30:15Z |

Hi,

Did any one tried calling a Webservice published in teamworks from a HTML page through jquery .ajax call.

 

Any help is appreciated..

 

Thanks

-

Sam

 

  • kolban
    kolban
    3314 Posts
    ACCEPTED ANSWER

    Re: Call WebService published in teamworks

    ‏2013-09-16T15:15:30Z  in response to SamBPM

    By webservice, do you mean a SOAP/HTTP exposed service?  My understanding is that it is extremely difficult to make a SOAP/HTTP request from a browser and instead one should probably be looking at using REST APIs to make the call back to the server.  What is the effect you wish to achieve?  An exposed BPM service can be started through a REST request without exposing it as a Web Service (SOAP/HTTP).

    Neil

    • SamBPM
      SamBPM
      7 Posts
      ACCEPTED ANSWER

      Re: Call WebService published in teamworks

      ‏2013-09-16T23:58:20Z  in response to kolban

      Thanks for the reply Neil.

      Yes  i want to Make SOAP/HTTP request, i created a SOAP callable webservice in Lombardi 7.2  and i want this to be called from a html page.

      I am trying this to achive this with Jquery.ajax but i am getting SOAP fault response.

       

      -

      Sam

      • kolban
        kolban
        3314 Posts
        ACCEPTED ANSWER

        Re: Call WebService published in teamworks

        ‏2013-09-17T00:33:01Z  in response to SamBPM

        Hi Sam,

        Oooh ... I wish it were a later version of BPM.  Starting from 7.5, IBM supplied REST APIs natively in the product which (in my opinion) are so much easier to call from a browser than SOAP/HTTP Web Services.  However, since you are at 7.2 ... let us see what we can do.  The first thing I would suggest is to make a working SOAP/HTTP call to the server using a tool such as "soapUI".  Make sure that works exactly as you like it to.  Once done, you can examine the HTTP traffic and see exactly what it was composed off.  Once you know that, we will be "out of the BPM game".   Your challenge then will be to make exactly that HTTP request from your browser technology.

        Another possibility would be to use a WAS server (did 7.2 come with a WAS server?) and expose a REST service from a Servlet.  You can then call that servlet from REST.  The implementation of the Servlet could then make a real WSDL defined Web Service call and effectively be a REST proxy.

        Either that or scour the web and see what you can find on making SOAP/HTTP calls from a browser.  My opinion is that SOAP/HTTP is awesome for app to app interactions but was believed to be "too expensive" for browser to app interactions.  As such the world seems to have "favored" raw technical REST requests as the browser to app connection even though this looses a ton of goodness compared to SOAP/HTTP web services.

        Neil

        • SeaAndHill
          SeaAndHill
          27 Posts
          ACCEPTED ANSWER

          Re: Call WebService published in teamworks

          ‏2013-09-17T14:01:06Z  in response to kolban

          hi neil,

             i am doing some investigating using REST api, but i found it only can the exposed BPD, if the BPD is not exposed, the REST api can not get it.Also, i am trying to use BPM web-api to update the BPD status in another Application not BPM portal,.

          The version that i am using is BPM8.5 ,does it support both of them? or what are the difference between them?

            Mark.

          • kolban
            kolban
            3314 Posts
            ACCEPTED ANSWER

            Re: Call WebService published in teamworks

            ‏2013-09-17T15:06:18Z  in response to SeaAndHill

            Hi Mark,

            See your other post on the difference between them.  It is a true statement that a BPD can not be executed by a REST call unless it is exposed... but that is my understanding of the meaning of exposed.  To my way of thinking, "exposed" means "This BPD is exposed to be invoked by some means outside of BPM internals".  When we expose a BPD we also define the set of users that are eligible to interact with it.

            Neil