5

Is it possible? I see no mention of a url_key in the Swagger docs.

I have a large database of product I need to import, and the names (which seem to determine the url) are not unique.

7

Although Swagger doesn't specify "url_key", you can add this attribute value by the following method:

{
  "product": {
    ...
    "customAttributes": [
      {
        "attributeCode": "url_key",
        "value": "<your_value>"
      }
    ]
  }
}

Note: Next time, you can use GET to know the product JSON structure first. Then any customized attributes can be created according to the JSON structure.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.