amzn / selling-partner-api-models

This repository contains OpenAPI models for developers to use when developing software to call Selling Partner APIs.
Apache License 2.0
585 stars 730 forks source link

[BUG] [SP-API] Updating an offer price to a product listing doesn't work #2785

Closed barruka closed 5 months ago

barruka commented 5 months ago

We are trying to update the price of a product via listings API, we have tried with v2020-09-01 and v2021-08-01, we got ACCEPTED in the response but after 30 minutes the price is never updated.

  {
    "sku": "f58b9597-2e11-4e3b-b23e-4786b00475d8",
    "status": "ACCEPTED",
    "submissionId": "beeb8d7642904dfe9f7e5b0a0d55de81",
    "issues": []
}

image

{
    "productType": "PRODUCT",
    "patches": [
        {
            "op": "replace",
            "path": "/attributes/purchasable_offer",
            "value": [
                {
                    "currency": "EUR",
                    "our_price": [
                        {
                            "schedule": [
                                {
                                    "value_with_tax": 10.49
                                }
                            ]
                        }
                    ],
                    "marketplace_id": "A1RKKUPIHCS9HS"
                }
            ]
        }
    ]
}

Endpoint:

https://sellingpartnerapi-eu.amazon.com/listings/2020-09-01/items/ADZ2XN1RK5LNB/f58b9597-2e11-4e3b-b23e-4786b00475d8?marketplaceIds=A1RKKUPIHCS9HS

method

PATCH

We hope you can give us some light!

barruka commented 5 months ago

OMG your doc is awfull... any how...

To everyone interesed: "value_with_tax": 10.49 MUST BE QUOTED (is so difficult to tell us about in the documentation????)

so, just changed to "value_with_tax": "10.49" and it works

chapmanjw commented 5 months ago

OMG your doc is awfull... any how...

To everyone interesed: "value_with_tax": 10.49 MUST BE QUOTED (is so difficult to tell us about in the documentation????)

so, just changed to "value_with_tax": "10.49" and it works

While the Listings APIs are flexible in that they will convert string values to their correct data types, the numeric form here is actually the correct one "value_with_tax": 10.49. Most likely there was a processing delay in reflecting the price update on Seller Central, not an issue with how the data was submitted.