You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Starting from the shopify-api-ruby 10.0.0 if the REST API is used there is no way to get weight or price-based shipping rates related to the particular ShippingZone resource.
shopify_api version: 10.0.0 and up
Expected behavior
The price_based_shipping_rates and weight_based_shipping_rates attributes of the ShippingZone REST resource should return an array of hashes or an empty array if there are no related rates.
It should work for all API versions.
Actual behavior
It returns the TypeError Exception
TypeError Exception: Return value: Expected type T.nilable(T::Hash[T.untyped, T.untyped]), got type Array with value [{...}]...
Steps to reproduce the problem
Get an existing ShippingZone by using REST API
Try to access its price_based_shipping_rates or weight_based_shipping_rates attribute
The text was updated successfully, but these errors were encountered:
Thanks for your patience with this! I've tracked down the root problem and we are working on a fix! Unfortunately, the problem seems to be a type misunderstanding upstream with our API at Shopify so I'm not in complete control of the fix. I see this root issue affecting several other issues within our REST resources here which is a bummer :(
As a workaround, you could use the rest client directly directly, though you'll have to parse the response accordingly.
Issue summary
Starting from the
shopify-api-ruby
10.0.0 if the REST API is used there is no way to get weight or price-based shipping rates related to the particular ShippingZone resource.shopify_api
version: 10.0.0 and upExpected behavior
The
price_based_shipping_rates
andweight_based_shipping_rates
attributes of the ShippingZone REST resource should return an array of hashes or an empty array if there are no related rates.It should work for all API versions.
Actual behavior
It returns the TypeError Exception
Steps to reproduce the problem
price_based_shipping_rates
orweight_based_shipping_rates attribute
The text was updated successfully, but these errors were encountered: