PUT /products/{productId}/pricing

⚠ Attention

When updating product price by more than 30% you will have to use the force token. Please see Product price protection section above.

Body Required

  • price number

    Price of product (used only if the product is without variants, otherwise it is in the variant data structure)

  • rrp number Deprecated

    Recommended retail price (if the product has variants, use this attribute only in the variant data structure)

  • force_price number

    Price may be overriden by ongoing campaign, if so then force_price field contains forced price, price cannot be updated when force_price is in effect

Responses

  • 200

    OK

  • 400

    Pricing protection error

    Hide response attributes Show response attributes object
    • errorCodes array[object]
      Hide errorCodes attributes Show errorCodes attributes array[object]
      • message string
      • errorCode string
      • errorAttributes object
    • result object
      Hide result attributes Show result attributes object
      • code integer
      • status string
      • message string
    • data object
      Hide data attributes Show data attributes object
      • key string
      • data object
        Hide data attributes Show data attributes object
        • forceToken string
        • variantIndex integer
PUT /products/{productId}/pricing
curl \
 -X PUT https://mpapi.proxy.omnicado.com/v1/products/{productId}/pricing?client_id=api_token_value \
 -H "Content-Type: application/json" \
 -d '{"price":1933.0,"rrp":2133.0,"force_price":2051.0}'
Request example
{
  "price": 1933.0,
  "rrp": 2133.0,
  "force_price": 2051.0
}
Request examples
{
  "price": 1933.0,
  "rrp": 2133.0,
  "force_price": 2051.0
}
Response examples (400)
{
  "errorCodes": [
    {
      "message": "Difference between current price ({currentPrice}) and new price ({newPrice}) for product \"{productId}\" is larger than 30% ({real percentage difference}). To confirm this change, use attached force token.",
      "errorCode": "VALIDATION_ERROR",
      "errorAttributes": {}
    }
  ],
  "result": {
    "code": 400,
    "status": "ERROR",
    "message": "Difference between current price ({currentPrice}) and new price ({newPrice}) for product \"{productId}\" is larger than 30% ({real percentage difference}). To confirm this change, use attached force token."
  },
  "data": {
    "key": "product.variants",
    "data": {
      "forceToken": "b3f7d1feca4c649e3493b466cbe0e6795bc6f679",
      "variantIndex": 0
    }
  }
}
Response examples (400)
{
  "errorCodes": [
    {
      "message": "Difference between current price ({currentPrice}) and new price ({newPrice}) for product \"{productId}\" is larger than 30% ({real percentage difference}). To confirm this change, use attached force token.",
      "errorCode": "VALIDATION_ERROR",
      "errorAttributes": {}
    }
  ],
  "result": {
    "code": 400,
    "status": "ERROR",
    "message": "Difference between current price ({currentPrice}) and new price ({newPrice}) for product \"{productId}\" is larger than 30% ({real percentage difference}). To confirm this change, use attached force token."
  },
  "data": {
    "key": "product.variants",
    "data": {
      "forceToken": "b3f7d1feca4c649e3493b466cbe0e6795bc6f679",
      "variantIndex": 0
    }
  }
}