Loading ...
Sorry, an error occurred while loading the content.

Why doesn't this work?

Expand Messages
  • Robert Nicholson
    Anybody know why this keeps returning an invalid number? sub lookup_bill { my $bill = shift(@_); my $fedex_wdsl =
    Message 1 of 7 , Oct 21, 2004
    • 0 Attachment
      Anybody know why this keeps returning an invalid number?

      sub lookup_bill {
      my $bill = shift(@_);

      my $fedex_wdsl =
      "http://www.xmethods.net/sd/2001/FedExTrackerService.wsdl";

      # my $fedex_search = SOAP::Lite->service("$fedex_wdsl");

      my $fedex_search = SOAP::Lite
      ->uri('urn:xmethodsFedEx')
      ->proxy('http://services.xmethods.net:80/perl/soaplite.cgi');

      my $results = $fedex_search ->
      getStatus(SOAP::Data->name("statusRequest")
      ->type("xsd:string")
      ->value(\SOAP::Data->value(
      SOAP::Data->name('trackingNumber' =>
      $bill)->type("xsd:string")
      ))
      );

      print "Results is $results\n";
      }

      The SOAP response from the site is always an invalid number.
    • Byrne Reese
      I do not see the XMethods service that you descibe. I see this one: http://www.xmethods.net/ve2/ViewListing.po?key=uuid:6289E092-E4AD-C7AB-C470-27868877ED68
      Message 2 of 7 , Oct 21, 2004
      • 0 Attachment
        I do not see the XMethods service that you descibe. I see this one:

        http://www.xmethods.net/ve2/ViewListing.po?key=uuid:6289E092-E4AD-C7AB-C470-27868877ED68

        Are they the same? I am not sure they are.

        But since I don't see it listed anymore, I can only believe that the
        service you are attempting to call doesn't exist anymore.

        Try using the one above, and let me know if you are successful.

        Byrne


        Robert Nicholson wrote:

        > Anybody know why this keeps returning an invalid number?
        >
        > sub lookup_bill {
        > my $bill = shift(@_);
        >
        > my $fedex_wdsl =
        > "http://www.xmethods.net/sd/2001/FedExTrackerService.wsdl";
        >
        > # my $fedex_search = SOAP::Lite->service("$fedex_wdsl");
        >
        > my $fedex_search = SOAP::Lite
        > ->uri('urn:xmethodsFedEx')
        >
        > ->proxy('http://services.xmethods.net:80/perl/soaplite.cgi');
        > <http://services.xmethods.net:80/perl/soaplite.cgi%27%29;>
        >
        > my $results = $fedex_search ->
        > getStatus(SOAP::Data->name("statusRequest")
        > ->type("xsd:string")
        > ->value(\SOAP::Data->value(
        > SOAP::Data->name('trackingNumber' =>
        > $bill)->type("xsd:string")
        > ))
        > );
        >
        > print "Results is $results\n";
        > }
        >
        > The SOAP response from the site is always an invalid number.
      • Robert Nicholson
        This seems to work for the result they return isn t the status. http://www.xmethods.com/ve2/ViewListing.po?serviceid=15 sub lookup_bill { my $bill = shift(@_);
        Message 3 of 7 , Oct 22, 2004
        • 0 Attachment
          This seems to work for the result they return isn't the status.

          http://www.xmethods.com/ve2/ViewListing.po?serviceid=15

          sub lookup_bill {
          my $bill = shift(@_);

          my $fedex_wdsl =
          "http://www.xmethods.net/sd/2001/FedExTrackerService.wsdl";

          my $fedex_search = SOAP::Lite->service("$fedex_wdsl");

          #my $fedex_search = SOAP::Lite
          # ->uri('urn:xmethodsFedEx')
          # ->proxy('http://services.xmethods.net:80/perl/soaplite.cgi');

          my $results = $fedex_search ->
          getStatus(SOAP::Data->type("xsd:string")->name(trackingNumber
          => $bill)
          );

          print "Results is $results\n";
          }

          On Oct 22, 2004, at 1:13 AM, Byrne Reese wrote:

          > I do not see the XMethods service that you descibe. I see this one:
          >
          > http://www.xmethods.net/ve2/ViewListing.po?key=uuid:6289E092-E4AD-
          > C7AB-C470-27868877ED68
          >
          > Are they the same? I am not sure they are.
          >
          > But since I don't see it listed anymore, I can only believe that the
          > service you are attempting to call doesn't exist anymore.
          >
          > Try using the one above, and let me know if you are successful.
          >
          > Byrne
          >
          >
          > Robert Nicholson wrote:
          >
          >> Anybody know why this keeps returning an invalid number?
          >>
          >> sub lookup_bill {
          >> my $bill = shift(@_);
          >>
          >> my $fedex_wdsl =
          >> "http://www.xmethods.net/sd/2001/FedExTrackerService.wsdl";
          >>
          >> # my $fedex_search = SOAP::Lite->service("$fedex_wdsl");
          >>
          >> my $fedex_search = SOAP::Lite
          >> ->uri('urn:xmethodsFedEx')
          >>
          >> ->proxy('http://services.xmethods.net:80/perl/soaplite.cgi');
          >> <http://services.xmethods.net:80/perl/soaplite.cgi%27%29;>
          >>
          >> my $results = $fedex_search ->
          >> getStatus(SOAP::Data->name("statusRequest")
          >> ->type("xsd:string")
          >> ->value(\SOAP::Data->value(
          >> SOAP::Data->name('trackingNumber' =>
          >> $bill)->type("xsd:string")
          >> ))
          >> );
          >>
          >> print "Results is $results\n";
          >> }
          >>
          >> The SOAP response from the site is always an invalid number.
          >
          >
        • Robert Nicholson
          I took at look at this service but how do you pass a sequence as an input parameter? my $results = $fedex_search -
          Message 4 of 7 , Oct 22, 2004
          • 0 Attachment
            I took at look at this service but how do you pass a sequence as an
            input parameter?

            my $results = $fedex_search ->
            FedEx_GetTrackingInfo(SOAP::Data->name("FedEx_GetTrackingInfo")
            ->type("FedEx_GetTrackingInfo")
            ->value(\SOAP::Data->value(
            SOAP::Data->type("xsd:string")->name("TrackingNumber"
            => $bill),
            SOAP::Data->type("xsd:string")->name("LicenseKey" =>
            $license)
            ))
            );


            On Oct 22, 2004, at 1:13 AM, Byrne Reese wrote:

            > I do not see the XMethods service that you descibe. I see this one:
            >
            > http://www.xmethods.net/ve2/ViewListing.po?key=uuid:6289E092-E4AD-
            > C7AB-C470-27868877ED68
            >
            > Are they the same? I am not sure they are.
            >
            > But since I don't see it listed anymore, I can only believe that the
            > service you are attempting to call doesn't exist anymore.
            >
            > Try using the one above, and let me know if you are successful.
            >
            > Byrne
            >
            >
            > Robert Nicholson wrote:
            >
            >> Anybody know why this keeps returning an invalid number?
            >>
            >> sub lookup_bill {
            >> my $bill = shift(@_);
            >>
            >> my $fedex_wdsl =
            >> "http://www.xmethods.net/sd/2001/FedExTrackerService.wsdl";
            >>
            >> # my $fedex_search = SOAP::Lite->service("$fedex_wdsl");
            >>
            >> my $fedex_search = SOAP::Lite
            >> ->uri('urn:xmethodsFedEx')
            >>
            >> ->proxy('http://services.xmethods.net:80/perl/soaplite.cgi');
            >> <http://services.xmethods.net:80/perl/soaplite.cgi%27%29;>
            >>
            >> my $results = $fedex_search ->
            >> getStatus(SOAP::Data->name("statusRequest")
            >> ->type("xsd:string")
            >> ->value(\SOAP::Data->value(
            >> SOAP::Data->name('trackingNumber' =>
            >> $bill)->type("xsd:string")
            >> ))
            >> );
            >>
            >> print "Results is $results\n";
            >> }
            >>
            >> The SOAP response from the site is always an invalid number.
            >
            >
          • jpeyser
            Robert, I m not sure whether you want to use FedEx or the USPS. However, in creating the sequence, it seems that your code contains an extra backslash.
            Message 5 of 7 , Oct 22, 2004
            • 0 Attachment
              Robert,
              I'm not sure whether you want to use FedEx or the USPS.
              However, in creating the sequence, it seems that your code contains an
              extra backslash.

              FedEx_GetTrackingInfo(SOAP::Data->name("FedEx_GetTrackingInfo")
              ->type("FedEx_GetTrackingInfo")
              ->value(SOAP::Data->value(

              Jonathan

              --- In soaplite@yahoogroups.com, Robert Nicholson <robert@e...> wrote:
              > I took at look at this service but how do you pass a sequence as an
              > input parameter?
              >
              > my $results = $fedex_search ->
              > FedEx_GetTrackingInfo(SOAP::Data->name("FedEx_GetTrackingInfo")
              > ->type("FedEx_GetTrackingInfo")
              > ->value(\SOAP::Data->value(
              > SOAP::Data->type("xsd:string")->name("TrackingNumber"
              > => $bill),
              > SOAP::Data->type("xsd:string")->name("LicenseKey" =>
              > $license)
              > ))
              > );
              >
              >
              > On Oct 22, 2004, at 1:13 AM, Byrne Reese wrote:
              >
              > > I do not see the XMethods service that you descibe. I see this one:
              > >
              > > http://www.xmethods.net/ve2/ViewListing.po?key=uuid:6289E092-E4AD-
              > > C7AB-C470-27868877ED68
              > >
              > > Are they the same? I am not sure they are.
              > >
              > > But since I don't see it listed anymore, I can only believe that the
              > > service you are attempting to call doesn't exist anymore.
              > >
              > > Try using the one above, and let me know if you are successful.
              > >
              > > Byrne
              > >
              > >
              > > Robert Nicholson wrote:
              > >
              > >> Anybody know why this keeps returning an invalid number?
              > >>
              > >> sub lookup_bill {
              > >> my $bill = shift(@_);
              > >>
              > >> my $fedex_wdsl =
              > >> "http://www.xmethods.net/sd/2001/FedExTrackerService.wsdl";
              > >>
              > >> # my $fedex_search = SOAP::Lite->service("$fedex_wdsl");
              > >>
              > >> my $fedex_search = SOAP::Lite
              > >> ->uri('urn:xmethodsFedEx')
              > >>
              > >> ->proxy('http://services.xmethods.net:80/perl/soaplite.cgi');
              > >> <http://services.xmethods.net:80/perl/soaplite.cgi%27%29;>
              > >>
              > >> my $results = $fedex_search ->
              > >> getStatus(SOAP::Data->name("statusRequest")
              > >> ->type("xsd:string")
              > >> ->value(\SOAP::Data->value(
              > >> SOAP::Data->name('trackingNumber' =>
              > >> $bill)->type("xsd:string")
              > >> ))
              > >> );
              > >>
              > >> print "Results is $results\n";
              > >> }
              > >>
              > >> The SOAP response from the site is always an invalid number.
              > >
              > >
            • Robert Nicholson
              So the following isn t working. and I even pointed stubmaker.pl at the service and it also returns the same result. sub lookup_bill_dots { my $bill =
              Message 6 of 7 , Oct 22, 2004
              • 0 Attachment
                So the following isn't working.

                and I even pointed stubmaker.pl at the service and it also returns the
                same result.

                sub lookup_bill_dots {
                my $bill = shift(@_);

                my $fedex_wdsl =
                "http://ws2.serviceobjects.net/pt/PackTrack.asmx?WSDL";

                my $license = "XXXXXXXXX";

                my $fedex_search = SOAP::Lite
                -> uri('http://www.serviceobjects.com')
                -> on_action( sub { join '/',
                'http://www.serviceobjects.com', $_[1] })
                ->
                proxy('http://ws2.serviceobjects.net/pt/PackTrack.asmx');

                my $method = SOAP::Data->name('FedEx_GetTrackingInfo')
                ->attr ({ xmlns =>
                'http://www.serviceobjects.com'});

                my @params = (
                SOAP::Data->type("xsd:string")->name("TrackingNumber" => $bill),
                SOAP::Data->name("LicenseKey" => $license) );

                print $fedex_search->call($method => @params)->result;

                # my $results = $fedex_search ->
                #
                FedEx_GetTrackingInfo(SOAP::Data->type("xsd:string")-
                >name("TrackingNumber" => $bill),
                # SOAP::Data->name("LicenseKey" =>
                $license)
                # );

                # my $results = $fedex_search ->
                #
                FedEx_GetTrackingInfo(SOAP::Data->type("xsd:string")-
                >name("TrackingNumber" => $bill)
                # );

                # print "Results is $results\n";
                }

                tcsh% perl fedexSOAP.pl
                SOAP::Transport::HTTP::Client::send_receive: POST
                http://ws2.serviceobjects.net/pt/PackTrack.asmx HTTP/1.1
                Accept: text/xml
                Accept: multipart/*
                Content-Length: 604
                Content-Type: text/xml; charset=utf-8
                SOAPAction: http://www.serviceobjects.com/FedEx_GetTrackingInfo

                <?xml version="1.0" encoding="UTF-8"?><SOAP-ENV:Envelope
                SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
                xmlns:xsd="http://www.w3.org/1999/XMLSchema"
                xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
                xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
                xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"><SOAP-ENV:
                Body><FedEx_GetTrackingInfo
                xmlns="http://www.serviceobjects.com"><TrackingNumber
                xsi:type="xsd:string">836656293358</TrackingNumber><LicenseKey
                xsi:type="xsd:string">XXXXXXXXX</LicenseKey></FedEx_GetTrackingInfo></
                SOAP-ENV:Body></SOAP-ENV:Envelope>
                SOAP::Transport::HTTP::Client::send_receive: HTTP/1.1 200 OK
                Cache-Control: private, max-age=0
                Connection: close
                Date: Sat, 23 Oct 2004 03:34:28 GMT
                Server: Microsoft-IIS/5.0
                Content-Length: 491
                Content-Type: text/xml; charset=utf-8
                Client-Date: Sat, 23 Oct 2004 03:34:28 GMT
                Client-Peer: 66.12.67.61:80
                Client-Response-Num: 1
                X-AspNet-Version: 1.1.4322
                X-Powered-By: ASP.NET

                <?xml version="1.0" encoding="utf-8"?><soap:Envelope
                xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
                xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:
                Body><FedEx_GetTrackingInfoResponse
                xmlns="http://
                www.serviceobjects.com/"><FedEx_GetTrackingInfoResult><Error><Desc>Input
                can not be less than zero
                length</Desc><Number>1</Number></Error></FedEx_GetTrackingInfoResult></
                FedEx_GetTrackingInfoResponse></soap:Body></soap:Envelope>
                HASH(0x9f00)tcsh%




                On Oct 22, 2004, at 10:30 AM, jpeyser wrote:

                >
                > Robert,
                > I'm not sure whether you want to use FedEx or the USPS.
                > However, in creating the sequence, it seems that your code contains an
                > extra backslash.
                >
                > FedEx_GetTrackingInfo(SOAP::Data->name("FedEx_GetTrackingInfo")
                >             ->type("FedEx_GetTrackingInfo")
                >                   ->value(SOAP::Data->value(
                >
                > Jonathan
                >
                > --- In soaplite@yahoogroups.com, Robert Nicholson <robert@e...> wrote:
                > > I took at look at this service but how do you pass a sequence as an 
                > > input parameter?
                > >
                > > my $results = $fedex_search ->
                > >         
                > FedEx_GetTrackingInfo(SOAP::Data->name("FedEx_GetTrackingInfo")
                > >            ->type("FedEx_GetTrackingInfo")
                > >                  ->value(\SOAP::Data->value(
                > >                 
                > SOAP::Data->type("xsd:string")->name("TrackingNumber" 
                > > => $bill),
                > >                  SOAP::Data->type("xsd:string")->name("LicenseKey"
                > => 
                > > $license)
                > >            ))
                > >          );
                > >
                > >
                > > On Oct 22, 2004, at 1:13 AM, Byrne Reese wrote:
                > >
                > > > I do not see the XMethods service that you descibe. I see this
                > one:
                > > >
                > > > http://www.xmethods.net/ve2/ViewListing.po?key=uuid:6289E092-E4AD-
                > > > C7AB-C470-27868877ED68
                > > >
                > > > Are they the same? I am not sure they are.
                > > >
                > > > But since I don't see it listed anymore, I can only believe that
                > the 
                > > > service you are attempting to call doesn't exist anymore.
                > > >
                > > > Try using the one above, and let me know if you are successful.
                > > >
                > > > Byrne
                > > >
                > > >
                > > > Robert Nicholson wrote:
                > > >
                > > >> Anybody know why this keeps returning an invalid number?
                > > >>
                > > >> sub lookup_bill {
                > > >>      my $bill = shift(@_);
                > > >>
                > > >>      my $fedex_wdsl =
                > > >> "http://www.xmethods.net/sd/2001/FedExTrackerService.wsdl";
                > > >>
                > > >> #    my $fedex_search = SOAP::Lite->service("$fedex_wdsl");
                > > >>
                > > >>      my $fedex_search = SOAP::Lite
                > > >>           ->uri('urn:xmethodsFedEx')
                > > >>           
                > > >> ->proxy('http://services.xmethods.net:80/perl/soaplite.cgi'); 
                > > >> <http://services.xmethods.net:80/perl/soaplite.cgi%27%29;>
                > > >>
                > > >>      my $results = $fedex_search ->
                > > >>          getStatus(SOAP::Data->name("statusRequest")
                > > >>              ->type("xsd:string")
                > > >>              ->value(\SOAP::Data->value(
                > > >>            SOAP::Data->name('trackingNumber' =>
                > > >> $bill)->type("xsd:string")
                > > >>            ))
                > > >>      );
                > > >>
                > > >>      print "Results is $results\n";
                > > >> }
                > > >>
                > > >> The SOAP response from the site is always an invalid number.
                > > >
                > > >
                >
                >
                >
                >
                >
                >
                > Yahoo! Groups Sponsor
                >
                > ADVERTISEMENT
                > <f2_free2_300x250_def_0904.gif>
                > <l.gif>
                >
                > Yahoo! Groups Links
                >
                > • To visit your group on the web, go to:
                > http://groups.yahoo.com/group/soaplite/
                >  
                > • To unsubscribe from this group, send an email to:
                > soaplite-unsubscribe@yahoogroups.com
                >  
                > • Your use of Yahoo! Groups is subject to the Yahoo! Terms of
                > Service.
                >
                >
              • Robert Nicholson
                Finally got it to work sub lookup_bill_dots { my $bill = shift(@_); my $fedex_wdsl = http://ws2.serviceobjects.net/pt/PackTrack.asmx?WSDL ; my $license =
                Message 7 of 7 , Oct 22, 2004
                • 0 Attachment
                  Finally got it to work

                  sub lookup_bill_dots {
                  my $bill = shift(@_);

                  my $fedex_wdsl =
                  "http://ws2.serviceobjects.net/pt/PackTrack.asmx?WSDL";

                  my $license = "XXXXXXXXXXX";

                  my $fedex_search = SOAP::Lite
                  -> uri('http://www.serviceobjects.com/')
                  -> on_action( sub { join '/',
                  'http://www.serviceobjects.com', $_[1] })
                  ->
                  proxy('http://ws2.serviceobjects.net/pt/PackTrack.asmx');

                  my $method = SOAP::Data->name('FedEx_GetTrackingInfo')
                  -> attr({ xmlns =>
                  'http://www.serviceobjects.com/'});

                  my @params = (

                  SOAP::Data->type("xsd:string")->name("TrackingNumber" => $bill)
                  ->uri('http://www.serviceobjects.com/'),
                  SOAP::Data->name("LicenseKey" => $license)
                  ->uri('http://www.serviceobjects.com/')
                  );

                  print $fedex_search->call($method => @params)->result;
                  }
                Your message has been successfully submitted and would be delivered to recipients shortly.