Custom Carrier Service not requesting rates from our carrier callback url

New Member
6 0 0

Hello

We are using custom carrier service which is returning carrier informations for order. In case we change the basket exactly this procedure:

1. add two products into cart
2. go to the shopping process and fill up user data
3. continue to the page where you can select shipping method
4. select the shipping method which is provided by our carrier service
5. go back to the basket and remove a product
6. add a new product
7. continue to the checkout and after coming to the step to choose shipping method this is not displayed and a error message popup saying: basket has changed please select a shipping method (in red in the top) but NO shipping method is available to select.

Here is how we use the custom carrier service:


based on the documentation https://help.shopify.com/api/reference/carrierservice we create a carrier service

POST /admin/carrier_services.json
{"carrier_service":{"callback_url":"https://api.shirtplatform.com/webservices/spring/shopify/connectors/9/carriers/rates","carrier_servi... Carrier Service","active":true}

This carrier service we select in the shopify shop as: calculated rates - Shirtplatform Carrier Service

This carrier service is also listening on address: https://api.shirtplatform.com/webservices/spring/shopify/connectors/9/carriers/rates

and is returning list of carriers and prices in format based on documentation. It also works as we see the carrier available in the basket.

We have switched on logging of those requests and we know when shopify is requesting for carrier rates.

The problem is however, that in case described in the top Shopify platform is NOT REQUESTING the list of carriers form the carrier service. In case it is requesting the carrier service then this is also disaplayed in the shopping process correctly.

Maybe this is related to the shopify caching you describing in the documnetation or we have some logical issue in the setup which we dont understand:

Shopify provides server-side caching to reduce the number of external requests. Any shipping rate estimate request that identically matches the following fields will be retrieved from Shopify's cache of the initial response:
*       variant ids
*       default shipping box weight and dimensions
*       variant quantities
*       carrier service id
*       origin address
*       destination address
*       item weights and signatures
If any of these fields differ, or if the cache has expired since the original request, then new shipping rates will be requested from the external provider.

At the moment we do not use the custom carrier service as it is not reliable but we can switch it on if required.

Here are few examples how shopify is calling our service:

35.196.44.204 - - [09/Apr/2018:14:47:38 +0200] "POST /webservices/spring/shopify/connectors/23/carriers/rates HTTP/1.1" 200 440 "-" "Ruby"
35.231.177.72 - - [09/Apr/2018:14:48:40 +0200] "POST /webservices/spring/shopify/connectors/23/carriers/rates HTTP/1.1" 200 440 "-" "Ruby"
35.231.159.184 - - [09/Apr/2018:14:50:07 +0200] "POST /webservices/spring/shopify/connectors/23/carriers/rates HTTP/1.1" 200 440 "-" "Ruby"
 

Thank you!

 

 

0 Likes
New Member
6 0 0

In case Shopify does not display shipping method then the customer waits long time and after about 5 - 8 seconds it looks like shopify server is not able to cerate a connection to carrier service. (See attached image).

After we change for example amount of product or name or anything in the cart / address then the next request start working and shopify will get requested rate.

It looks for us as the shopify for some reason do not get a answer from carrier service and cache this as a valid answer which is incorrect.

0 Likes
Shopify Partner
43 0 5

I've had a carrier service going for two years, and I've recently started getting feedback from customers about not getting rates, and notifications like for Michal here.

 

I've witnessed it myself too; and there was no incoming traffic to the server (although is there was an SSL connection issue, I would not have been able to see it.). 

 

What is Shopify doing to report technical problems with the carrier service calls?

0 Likes
New Member
6 0 0

I opened a official ticket about this issue with shopify support. After about 1 week they told me they are not able to help me and i should open a ticket here. I think the issue is with some backend server in shopify cloud which dont work correctly with carrier service calls / making exception and is not executing the callback.

 

Shopify can you reply on this please? Looks im not the only one with this issue.

 

@Thomas - since when are you geting complains from your customers?

 

 

0 Likes
Highlighted
Shopify Partner
43 0 5

One pretty smalltime shop reported 3 incidents (involving customer feeback) in the first 20 days of march. So like 6 weeks ago, or more..

0 Likes
Shopify Staff
Shopify Staff
1555 79 240

Hello everyone.

We had been seeing some issues regarding requests for shipping rates not hitting rate provider servers. This did in fact turn out to be an issue on our end and a fix has since been deployed. Is anybody here still experiencing the issue?

Cheers.

0 Likes
Shopify Partner
9 0 0

I do!

0 Likes
Shopify Staff
Shopify Staff
1555 79 240

Hey @RRStoyanov - Can you go into more detail for me to ensure the issue is the same?

0 Likes
Shopify Partner
9 0 0

How I create the service: 

        $data = [
            "carrier_service" => [
                "name"                 => "My App Shipping Rate Provider",
                "callback_url"         => "https://hidden.url/shopify/my-app/checkout/shipping",
                "service_discovery"    => true,
                "carrier_service_type" => 'api',
            ],
        ];

What is my response when the callback hits (also tried without "rates" key). It's json, verified several times. Also I see get the calls, but shopify doesn't display anything.

        $responseData = [
            "rates" => [
                [
                    "service_name"      => "My Shipping",
                    "description"       => "Includes tracking and insurance",
                    "service_code"      => "my_shipping",
                    "currency"          => "GBP",
                    "total_price"       => 123,
                    'min_delivery_date' => '2017-11-11T00:00:00.000Z',
                    'max_delivery_date' => '2020-11-12T00:00:00.000Z',
                ],
            ],
        ];

Store front

http://prntscr.com/jaw0nh

Admin

http://prntscr.com/jaw1r3

Checking zone and provider via API

http://prntscr.com/jaw33t

 

I'm second day on this :(

0 Likes
Shopify Partner
9 0 0

As additional info - on another store from another app I see this

http://prntscr.com/jawjtk

while mine has only this

http://prntscr.com/jawk99

0 Likes