How can I remove a custom attribute from a product via REST? Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern) Announcing the arrival of Valued Associate #679: Cesar Manara Unicorn Meta Zoo #1: Why another podcast?How can i set a name or custom attribute for a specific storeview through REST API?The requested Payment Method is not available When creating an orderHow to return a JSON object with a custom REST API in Magento 2?Unable to update custom column value of sales_order via Rest APIGet product custom attribute data Magento 2?How to clear a custom option via REST product updateUnable to create customer using curl commandHow to check if custom product attribute existsHow to get product via attribute value or label?Export custom option via REST interface

How can I make names more distinctive without making them longer?

Can an alien society believe that their star system is the universe?

Output the ŋarâþ crîþ alphabet song without using (m)any letters

Why are there no cargo aircraft with "flying wing" design?

How to react to hostile behavior from a senior developer?

What is Wonderstone and are there any references to it pre-1982?

How to call a function with default parameter through a pointer to function that is the return of another function?

What is the logic behind the Maharil's explanation of why we don't say שעשה ניסים on Pesach?

Why did the Falcon Heavy center core fall off the ASDS OCISLY barge?

The logistics of corpse disposal

Why light coming from distant stars is not discreet?

Short Story with Cinderella as a Voo-doo Witch

Error "illegal generic type for instanceof" when using local classes

Identify plant with long narrow paired leaves and reddish stems

What does an IRS interview request entail when called in to verify expenses for a sole proprietor small business?

How do I stop a creek from eroding my steep embankment?

What exactly is a "Meth" in Altered Carbon?

Check which numbers satisfy the condition [A*B*C = A! + B! + C!]

How to bypass password on Windows XP account?

Echoing a tail command produces unexpected output?

Identifying polygons that intersect with another layer using QGIS?

2001: A Space Odyssey's use of the song "Daisy Bell" (Bicycle Built for Two); life imitates art or vice-versa?

Okay to merge included columns on otherwise identical indexes?

When a candle burns, why does the top of wick glow if bottom of flame is hottest?



How can I remove a custom attribute from a product via REST?



Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)
Announcing the arrival of Valued Associate #679: Cesar Manara
Unicorn Meta Zoo #1: Why another podcast?How can i set a name or custom attribute for a specific storeview through REST API?The requested Payment Method is not available When creating an orderHow to return a JSON object with a custom REST API in Magento 2?Unable to update custom column value of sales_order via Rest APIGet product custom attribute data Magento 2?How to clear a custom option via REST product updateUnable to create customer using curl commandHow to check if custom product attribute existsHow to get product via attribute value or label?Export custom option via REST interface



.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








3















I can add or change a custom attribute of a product, i.e. via



curl -X PUT --header "Content-Type: application/json" 
--header "Accept: application/json"
--header "Authorization: Bearer MYTOKEN" -d '"product":
"id":1,
"attribute_set_id":10,
"name": "Testproduct",
"sku": "test",
"custom_attributes": [

"attribute_code": "test_attribute",
"value": "the value"

]
,
"saveOptions":true' "https://magentohost/rest/default/V1/products/test"


but how can I remove that attribute(-value) again?



Using the admin-backend, I can remove it by setting its value to an empty string, however trying that with the rest api does not change anything. (just as if I leave out the attribute)
I also tried it with '"value": null', but then I get an error "Error occurred during "custom_attributes" processing. Value is not set for attribute code "test_attribute""



I am using Magento 2.1.3 (EE)










share|improve this question






























    3















    I can add or change a custom attribute of a product, i.e. via



    curl -X PUT --header "Content-Type: application/json" 
    --header "Accept: application/json"
    --header "Authorization: Bearer MYTOKEN" -d '"product":
    "id":1,
    "attribute_set_id":10,
    "name": "Testproduct",
    "sku": "test",
    "custom_attributes": [

    "attribute_code": "test_attribute",
    "value": "the value"

    ]
    ,
    "saveOptions":true' "https://magentohost/rest/default/V1/products/test"


    but how can I remove that attribute(-value) again?



    Using the admin-backend, I can remove it by setting its value to an empty string, however trying that with the rest api does not change anything. (just as if I leave out the attribute)
    I also tried it with '"value": null', but then I get an error "Error occurred during "custom_attributes" processing. Value is not set for attribute code "test_attribute""



    I am using Magento 2.1.3 (EE)










    share|improve this question


























      3












      3








      3


      1






      I can add or change a custom attribute of a product, i.e. via



      curl -X PUT --header "Content-Type: application/json" 
      --header "Accept: application/json"
      --header "Authorization: Bearer MYTOKEN" -d '"product":
      "id":1,
      "attribute_set_id":10,
      "name": "Testproduct",
      "sku": "test",
      "custom_attributes": [

      "attribute_code": "test_attribute",
      "value": "the value"

      ]
      ,
      "saveOptions":true' "https://magentohost/rest/default/V1/products/test"


      but how can I remove that attribute(-value) again?



      Using the admin-backend, I can remove it by setting its value to an empty string, however trying that with the rest api does not change anything. (just as if I leave out the attribute)
      I also tried it with '"value": null', but then I get an error "Error occurred during "custom_attributes" processing. Value is not set for attribute code "test_attribute""



      I am using Magento 2.1.3 (EE)










      share|improve this question
















      I can add or change a custom attribute of a product, i.e. via



      curl -X PUT --header "Content-Type: application/json" 
      --header "Accept: application/json"
      --header "Authorization: Bearer MYTOKEN" -d '"product":
      "id":1,
      "attribute_set_id":10,
      "name": "Testproduct",
      "sku": "test",
      "custom_attributes": [

      "attribute_code": "test_attribute",
      "value": "the value"

      ]
      ,
      "saveOptions":true' "https://magentohost/rest/default/V1/products/test"


      but how can I remove that attribute(-value) again?



      Using the admin-backend, I can remove it by setting its value to an empty string, however trying that with the rest api does not change anything. (just as if I leave out the attribute)
      I also tried it with '"value": null', but then I get an error "Error occurred during "custom_attributes" processing. Value is not set for attribute code "test_attribute""



      I am using Magento 2.1.3 (EE)







      magento-2.1 attributes product-attribute rest custom-attributes






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited 14 mins ago









      Muhammad Anas

      622320




      622320










      asked Feb 7 '17 at 16:37









      Tim RiemenschneiderTim Riemenschneider

      164




      164




















          0






          active

          oldest

          votes












          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "479"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f158606%2fhow-can-i-remove-a-custom-attribute-from-a-product-via-rest%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Magento Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f158606%2fhow-can-i-remove-a-custom-attribute-from-a-product-via-rest%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Can not update quote_id field of “quote_item” table magento 2Magento 2.1 - We can't remove the item. (Shopping Cart doesnt allow us to remove items before becomes empty)Add value for custom quote item attribute using REST apiREST API endpoint v1/carts/cartId/items always returns error messageCorrect way to save entries to databaseHow to remove all associated quote objects of a customer completelyMagento 2 - Save value from custom input field to quote_itemGet quote_item data using quote id and product id filter in Magento 2How to set additional data to quote_item table from controller in Magento 2?What is the purpose of additional_data column in quote_item table in magento2Set Custom Price to Quote item magento2 from controller

          How to solve knockout JS error in Magento 2 Planned maintenance scheduled April 23, 2019 at 23:30 UTC (7:30pm US/Eastern) Announcing the arrival of Valued Associate #679: Cesar Manara Unicorn Meta Zoo #1: Why another podcast?(Magento2) knockout.js:3012 Uncaught ReferenceError: Unable to process bindingUnable to process binding Knockout.js magento 2Cannot read property `scopeLabel` of undefined on Product Detail PageCan't get Customer Data on frontend in Magento 2Magento2 Order Summary - unable to process bindingKO templates are not loading in Magento 2.1 applicationgetting knockout js error magento 2Product grid not load -— Unable to process binding Knockout.js magento 2Product form not loaded in magento2Uncaught ReferenceError: Unable to process binding “if: function()return (isShowLegend()) ” magento 2

          Nissan Patrol Зміст Перше покоління — 4W60 (1951-1960) | Друге покоління — 60 series (1960-1980) | Третє покоління (1980–2002) | Четверте покоління — Y60 (1987–1998) | П'яте покоління — Y61 (1997–2013) | Шосте покоління — Y62 (2010- ) | Посилання | Зноски | Навігаційне менюОфіційний український сайтТест-драйв Nissan Patrol 2010 7-го поколінняNissan PatrolКак мы тестировали Nissan Patrol 2016рвиправивши або дописавши її