Amazon MWS Feed API Issue in updating Order status

2019-04-14 20:17发布

I am working on amazon mws feed api to update the order status from my site.
when i call to SubmitFeed Api, it is submitted successfully. But, when i call to GetFeedSubmissionResult, its returns me an error stating :

        <Result>
            <MessageID>1</MessageID>
            <ResultCode>Error</ResultCode>
            <ResultMessageCode>25</ResultMessageCode>
            <ResultDescription>We are unable to process the XML feed because one or more items are invalid. Please re-submit the feed.</ResultDescription>
        </Result>

Here is the my xml :

<?xml version="1.0" encoding="UTF-8"?>
<AmazonEnvelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="amzn-envelope.xsd">
    <Header>
        <DocumentVersion>1.01</DocumentVersion>
        <MerchantIdentifier>Maxvite Store</MerchantIdentifier>
    </Header>
    <MessageType>OrderFulfillment</MessageType>
    <Message>
        <MessageID>1</MessageID>
        <OrderFulfillment>
            <AmazonOrderID>123-5454545-5454545</AmazonOrderID>
            <MerchantOrderID>123456</MerchantOrderID>
            <MerchantFulfillmentID>123456</MerchantFulfillmentID>
            <FulfillmentDate>12-02-2013T04:23:00Z</FulfillmentDate>
            <FulfillmentData>
                <CarrierCode>UPS</CarrierCode>
                <ShippingMethod>UPS Ground</ShippingMethod>
                <ShipperTrackingNumber>123456</ShipperTrackingNumber>
            </FulfillmentData>
         </OrderFulfillment>
    </Message>
</AmazonEnvelope>

Thanks in advance

4条回答
We Are One
2楼-- · 2019-04-14 20:34

I have changed "CarrierCode" from 'Fed Ex' to 'FedEx' - Removed the space and it is working fine now.

查看更多
等我变得足够好
3楼-- · 2019-04-14 20:36

Remove the tag: 123456

it should be either "AmazonOrderID" or "MerchantOrderID".

You can leave out the cantainer.

查看更多
来,给爷笑一个
4楼-- · 2019-04-14 20:47

You're missing the <item> section:

<Item>
     <MerchantOrderItemID>1234567</MerchantOrderItemID>
     <MerchantFulfillmentItemID>1234567</MerchantFulfillmentItemID>
     <Quantity>2</Quantity>
</Item>

Although the XSD shows minOccurs="0", it may required in some circumstances. (I've found some weird behaviors with some of the feeds)

That being said, the MWS forum is reporting an identical issue affecting multiple people, so it could be a MWS thing...

查看更多
爱情/是我丢掉的垃圾
5楼-- · 2019-04-14 20:59

Your feed does not validate against the XSD schema. You cannot specify both AmazonOrderID and MerchantOrderID in the same feed (it is specified as choice in the OrderFulfillment.xsd)

Also, your FulfillmentDate should read 2013-02-12T04:23:00+00:00.

The following feed is changed accordingly and does validate:

<?xml version="1.0" encoding="UTF-8"?>
<AmazonEnvelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="amzn-envelope.xsd">
    <Header>
        <DocumentVersion>1.01</DocumentVersion>
        <MerchantIdentifier>Maxvite Store</MerchantIdentifier>
    </Header>
    <MessageType>OrderFulfillment</MessageType>
    <Message>
        <MessageID>1</MessageID>
        <OrderFulfillment>
            <AmazonOrderID>123-5454545-5454545</AmazonOrderID>
            <MerchantFulfillmentID>123456</MerchantFulfillmentID>
            <FulfillmentDate>2013-02-12T04:23:00+00:00</FulfillmentDate>
            <FulfillmentData>
                <CarrierCode>UPS</CarrierCode>
                <ShippingMethod>UPS Ground</ShippingMethod>
                <ShipperTrackingNumber>123456</ShipperTrackingNumber>
            </FulfillmentData>
         </OrderFulfillment>
    </Message>
</AmazonEnvelope>

Hope this helps.

查看更多
登录 后发表回答