Untitled Document
Results 1 to 2 of 2

Thread: ebay.shiprush.com integration with shiprush web

  1. #1
    I am trying to implement Web Shipping Javascript SDK for the first time. My credentials only work at ebay.shiprush.com and not my.shiprush.com.

    This is my code:
    In webpage:
    Code:
    <link href="https://ebay.shiprush.com/static.shiprush.com/ship.app/api/webshipping.integration.client.css" rel='stylesheet' type='text/css' />
    <script src="https://ebay.shiprush.com/static.shiprush.com/ship.app/api/webshipping.integration.client.js"></script>
    js:
    Code:
    function openShipRush(){
        let shipment = {
            ShipTo : {
                Name: 'John Doe',
                Address1: '1 Main St',
                City: 'Cincinnati',
                State: 'OH',
                PostalCode: '45140',
                Country: 'US',
                Phone: '5131234567'
            },
            CarrierTypeName: "USPS",
            ServiceTypeName: "USPSPriority",  
            Packages: [{
                Weight: 1, 
                WeightOunces: 0, 
                Length: 4,
                Width: 4,
                Height: 4
            }]
        };
    
    shipRushClient.Open(
        {
            //MyShipRushWebsite: 'ebay.shiprush.com',
            Shipment: shipment,
            OnShipmentCompleted: function (data) {
                alert(data.Shipment.TrackingNumber);
                // Return "true" to close shipping form
                return true;
            }
        });
    If I don't include MyShipRushWebsite: 'ebay.shiprush.com' in js and I log into ebay.shiprush.com before clicking button to trigger shipRushClient.Open, the shiprush web client works as expected. However, if I am not logged in to ebay.shiprush.com ahead of time, js will launch my.shiprush.com login. My eBay credentials do not work there. I thought I could resolve that by adding MyShipRushWebsite: 'ebay.shiprush.com' as shown in the code above. However, when I add that I get an error. In the console I see that my web application is trying to launch https://mywebsite.com/ebay.shiprush....adShipmentView. Note: Mywebsite is the URL of my web application that is trying to launch the shiprush web plugin. I believe that I need it to go to https://ebay.shiprush.com/ShipButton...adShipmentView, right?

    Is this a CORS problem? Is CORS configured differently on my.shiprush.com than it is on ebay.shiprush.com? How can I get my Javascript to launch the ebay.shiprush.com login rather than my.shiprush.com?
    Last edited by parts_rescue; 02-12-2019 at 11:36 AM.
    Reply With Quote

  2. #2

    Join Date
    Apr 2004
    Posts
    16,781
    SYSOPS is offline
    We've opened Case 70986 to review this further. Currently there isn't a control in the shipRushClient.Open call.

    Thank you,
    SYSOPS
    Have Questions? Ask the ShipRush Knowledge Base: https://shiprush.com/kbase
    Reply With Quote

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •