5 Replies Latest reply: Dec 1, 2010 4:24 PM by Sasha_E RSS

Problem in Integrating Jasper Wireless API

Newbie

Hi,

 

I am trying to use Jasper's API with PHP. I have downloaded and tested out the PHP sample for the terminal "TerminalDetails".

Unfortunately I don't retrieve data for the other terminals like "GetTerminalUsage", "GetTerminalUsageDataDetails" or "GetTerminalUsageSmsDetails".

 

The only reason that I can figure is the request parameter that I pass. In the PHP sample the XML header differs a little bit from that in the online documentation. There I retrieve the data for the terminal "GetTerminalDetails". However if I use the sample from the online documentation for the same terminal, I don't retrieve again nothing. I suppose the sample from the online documentation isn't proper.

 

Can somebody help me out please?

  • Re: Problem in Integrating Jasper Wireless API
    Newbie

    Hi Sasha,

     

    The three calls that you mentioned are defined in a different WSDL file. In your PHP code, please refer to Billing.wsdl instead of Terminal.wsdl.

     

    You can see the list of WSDL files by going to the "Overview -> Get WSDL Files" section in the API documentation.

     

    Thanks,

     

    -- Terry

    • Re: Problem in Integrating Jasper Wireless API
      Newbie

      Awesome! Thank you, that was really the reason. Who could have thought it's another wsdl-file. "terminal.wsdl" sounds more matching to all Terminals than "Billing.wsdl". Anyhow I am getting this error message now:

       

      faultcode: SOAP-ENV:Server faultstring: Array faultDetail:  response: HTTP/1.1 100 Continue  HTTP/1.1 500 Internal Server Error Server: Apache-Coyote/1.1 Accept: text/xml, text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2 SOAPAction: "" Content-Type: text/xml;charset=utf-8 Content-Length: 601 Date: Wed, 01 Dec 2010 22:05:34 GMT Connection: close  SOAP-ENV:Server200200No terminal usage foundcom.jasperwireless.ws.ApiExceptioniccid=8988650507770002000

       

      Does that mean, it doesn't find the device with iccid?

      "GetTerminalDetails" finds that device.

      • Re: Problem in Integrating Jasper Wireless API
        Newbie

        Hi Sasha,

         

        Maybe you are trying to get the usage for the current month? Please use GetTerminalDetails instead. From the API documentation for that call:

         

        Retrieves the terminal usage of a given month (completed billing cycle only) for the terminal identified by ICCID. The return result contains total and billable volumes for data, voice and SMS. To get current month's usage of a terminal, please use GetTerminalDetails call and the MonthToDateUsage fields.
        If there is no terminal usage found for the given terminal, a SOAP fault with error code 200200 will be returned.

         

        Thanks,

         

        -- Terry

        • Re: Problem in Integrating Jasper Wireless API
          Newbie

          I actually tried to call "GetTerminalUsageDataDetails" in order to store information like 'session_charging_id', 'sessionStartTime', 'duration', 'dataVolume' into our MySQL DB.

          But unfortunately, the online documentation says the response doesn't have the 'session_charging_id'. Only the other three.

          Nevertheless the first problem is, that I don't find any terminals for the given date. Is this date an interval that just goes back in time and I could give him a date back to 1 year. Or does it have to be the exact date of one billing cycle?

           

          The next problem is, I also try to store all the information of the Sms for a given month. Now the documentation doesn't provide me with any information how the request has to look like. I took that from "GetTerminalUsageDataDetails" and pass him also the "Billing.wsdl" file, but I get this:

           

          faultcode: SOAP-ENV:Server faultstring: Array faultDetail:  response: HTTP/1.1 100 Continue  HTTP/1.1 500 Internal Server Error Server: Apache-Coyote/1.1 Accept: text/xml, text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2 SOAPAction: "" Content-Type: text/xml;charset=utf-8 Content-Length: 776 Date: Wed, 01 Dec 2010 23:15:48 GMT Connection: close  SOAP-ENV:Server-1Undefinedorg.springframework.ws.soap.saaj.SaajSoapEnvelopeExceptionCould  not access envelope: Unable to create envelope from given source: ;  nested exception is  com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Unable to create  envelope from given source:

           

          I suppose the request parameters are wrong? Do you have them or can I find them somewhere?

          • Re: Problem in Integrating Jasper Wireless API
            Newbie

            Sorry my bad, the Iccids with the date that I used didn't exist. It is a billing cycle date and not just an interval date.

             

            Everything is working fine now. It seems like also "GetTerminalUsageSmsDetails" shares the same request parameter as "GetTerminalUsageDataDetails".

             

             

            Thank you very much Terry. You were a great help. I still would be stucked without you.

             

            P.S. I just wonder how to get also the information "session_charging_id", since "GetTerminalUsageDataDetails" doesn't provide me with that information.