cancel
Showing results for 
Search instead for 
Did you mean: 

Fault 1062: 'Shipping method is not available

Fault 1062: 'Shipping method is not available

I was trying to create an order in magento 1.9.2.4 via python using this https://github.com/fulfilio/python-magento repo.

 

I was able to successfully create customer, create address, cart , add product to cart , set payment method but when setting shipping method is giving me this error 

>>>client.cart_shipping.method(cart_id, {"method":"purchaseorder"})
Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/python-magento/magento/checkout.py", line 371, in method [quote_id, shipping_method, store_view]) File "/home/python-magento/magento/api.py", line 202, in call return self.client.call(self.session, resource_path, arguments) File "/usr/lib/python3.6/xmlrpc/client.py", line 1112, in __call__ return self.__send(self.__name, args) File "/usr/lib/python3.6/xmlrpc/client.py", line 1452, in __request verbose=self.__verbose File "/usr/lib/python3.6/xmlrpc/client.py", line 1154, in request return self.single_request(host, handler, request_body, verbose) File "/usr/lib/python3.6/xmlrpc/client.py", line 1170, in single_request return self.parse_response(resp) File "/usr/lib/python3.6/xmlrpc/client.py", line 1342, in parse_response return u.close() File "/usr/lib/python3.6/xmlrpc/client.py", line 656, in close raise Fault(**self._stack[0]) xmlrpc.client.Fault: <Fault 1062: 'Shipping method is not available'>

although I have check that this method i available using this 

>>>client.cart_shipping.list(cart_id)
[
    {
        "carrier": "purchaseorder",
        "carrier_title": "Purchase Order",
        "code": "purchaseorder_fixed",
        "method": "fixed",
        "method_description": None,
        "price": "0.0000",
        "error_message": None,
        "method_title": "Shipping",
        "carrierName": "Purchase Order"
    },
    {
        "carrier": "freeshipping",
        "carrier_title": "Shipping is pre-paid with UPS and added to your invoice",
        "code": "freeshipping_freeshipping",
        "method": "freeshipping",
        "method_description": None,
        "price": "0.0000",
        "error_message": None,
        "method_title": None,
        "carrierName": "Shipping is pre-paid with UPS and added to your invoice"
    }
]

I am in desperate need of help, please help me.

5 REPLIES 5

Re: Fault 1062: 'Shipping method is not available

Hello @aloknanone8804 

 

is free shipping method enable form admin ? 

 

Try to check with website and check which shippping enable for your store and use that shiping method 


Problem solved? Click Kudos & Accept as Solution!
Sunil Patel
Magento 2 Certified Professional Developer & Frontend Developer

Re: Fault 1062: 'Shipping method is not available

@Sunil Patel  Yes, checked it is enabled.
but still showing same problem.

Re: Fault 1062: 'Shipping method is not available

 

 

The problem is in the documentation of magento soap v2... When I have gone through the wsdl link, I have noticed somthing as below...

<message name="shoppingCartShippingMethodRequest">
<part name="sessionId" type="xsd:string"/>
<part name="quoteId" type="xsd:int"/>
<part name="method" type="xsd:string"/>
<part name="storeId" type="xsd:string"/>
</message>

As u can see, there's property method. Actually, there we have to add the shipping method... So u have to change ur code as below...

SoapObject shippingmethod = new SoapObject(MAGENTO_NAMESPACE,"shoppingCartShippingMethod");
shippingmethod.addProperty("sessionId", sessionId);
shippingmethod.addProperty("quoteId", quoteId);
shippingmethod.addProperty("method", "flatrate_error");
env.setOutputSoapObject(shippingmethod);
androidHttpTransport.call("", env);
Log.d("shippingMethod", shippingmethod.toString());
Object resultforShippingMethod = env.getResponse();
Log.d("ShippingMethod", resultforShippingMethod.toString());

Re: Fault 1062: 'Shipping method is not available

@leopham988f4b2 

I have set the property to method only. I have seen this solution here also

but not working anything else that night be wrong?

Re: Fault 1062: 'Shipping method is not available

Still stuck at this point, is there a way to place an order without this?
Please help.