• 0
Sign in to follow this  
Neto Braghetto

Problemas para atualizar atributos

Question

Pessoal alguém esta com problemas pra atualizar os atributos  de um produto?
Estou mandando um PUT pra https://api.mercadolibre.com/items/{ID} com os dados corretamente e mesmo assim o ML parece que ignora as atualizações dos atributos...

vou deixar um exemplo aqui Produto: (https://api.mercadolibre.com/items/MLB1193544392)

Alteração que eu fiz

{
  ...
  "attributes": [
    {
      "id": "MODEL",
      "value_name": "Slim strappede"
    },
    ...
  ],
  ...
}

Caso alguem queira ver o payload completo esta aqui:
 

{
  "title": "Chinelo Havaianas Feminino Slim Strapped Preto TEST",
  "price": 8000,
  "available_quantity": 11,
  "listing_type_id": "bronze",
  "description": {
    "plain_text": "A Havaianas Slim Strapped traz a novidade de estampa floral na tira, logo metálico colorido e a base lisa em três opções: a preta clássica e duas coloridas. Essa combinação é perfeita para quem é básico, mas quer dar um toque de estilo no visual."
  },
  "pictures": [
    {
      "source": "http://localhost:8888/img/products/1000x1000/1551983826-16469311055c8164d2826c33-89958635.jpg"
    },
    {
      "source": "http://localhost:8888/img/products/1000x1000/1551983834-3032974025c8164daa16a60-19134316.jpg"
    },
    {
      "source": "http://localhost:8888/img/products/1000x1000/1551983835-9707405845c8164db1b6549-32330505.jpg"
    },
    {
      "source": "http://localhost:8888/img/products/1000x1000/1551983835-15858453885c8164db9541f0-95756213.jpg"
    }
  ],
  "variations": [
    {
      "price": 8000,
      "available_quantity": 1,
      "attribute_combinations": [
        {
          "id": "COLOR",
          "value_id": null,
          "value_name": "Preto"
        },
        {
          "id": "SIZE",
          "value_id": null,
          "value_name": "34"
        }
      ],
      "attributes": [
        {
          "id": "MAIN_COLOR",
          "value_id": "2450295",
          "value_name": "Preto"
        },
        {
          "id": "GTIN",
          "value_id": "7890541339638",
          "value_name": "7890541339638"
        }
      ],
      "picture_ids": [
        "http://localhost:8888/img/products/1000x1000/1551983826-16469311055c8164d2826c33-89958635.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983834-3032974025c8164daa16a60-19134316.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983835-9707405845c8164db1b6549-32330505.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983835-15858453885c8164db9541f0-95756213.jpg"
      ],
      "id": 34008669044
    },
    {
      "price": 8000,
      "available_quantity": 3,
      "attribute_combinations": [
        {
          "id": "COLOR",
          "value_id": null,
          "value_name": "Preto"
        },
        {
          "id": "SIZE",
          "value_id": null,
          "value_name": "36"
        }
      ],
      "attributes": [
        {
          "id": "MAIN_COLOR",
          "value_id": "2450295",
          "value_name": "Preto"
        },
        {
          "id": "GTIN",
          "value_id": "7891224957453",
          "value_name": "7891224957453"
        }
      ],
      "picture_ids": [
        "http://localhost:8888/img/products/1000x1000/1551983826-16469311055c8164d2826c33-89958635.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983834-3032974025c8164daa16a60-19134316.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983835-9707405845c8164db1b6549-32330505.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983835-15858453885c8164db9541f0-95756213.jpg"
      ],
      "id": 34008669059
    },
    {
      "price": 8000,
      "available_quantity": 5,
      "attribute_combinations": [
        {
          "id": "COLOR",
          "value_id": null,
          "value_name": "Preto"
        },
        {
          "id": "SIZE",
          "value_id": null,
          "value_name": "38"
        }
      ],
      "attributes": [
        {
          "id": "MAIN_COLOR",
          "value_id": "2450295",
          "value_name": "Preto"
        },
        {
          "id": "GTIN",
          "value_id": "7891224957460",
          "value_name": "7891224957460"
        }
      ],
      "picture_ids": [
        "http://localhost:8888/img/products/1000x1000/1551983826-16469311055c8164d2826c33-89958635.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983834-3032974025c8164daa16a60-19134316.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983835-9707405845c8164db1b6549-32330505.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983835-15858453885c8164db9541f0-95756213.jpg"
      ],
      "id": 34008669071
    },
    {
      "price": 8000,
      "available_quantity": 2,
      "attribute_combinations": [
        {
          "id": "COLOR",
          "value_id": null,
          "value_name": "Preto"
        },
        {
          "id": "SIZE",
          "value_id": null,
          "value_name": "40"
        }
      ],
      "attributes": [
        {
          "id": "MAIN_COLOR",
          "value_id": "2450295",
          "value_name": "Preto"
        },
        {
          "id": "GTIN",
          "value_id": "7891224957477",
          "value_name": "7891224957477"
        }
      ],
      "picture_ids": [
        "http://localhost:8888/img/products/1000x1000/1551983826-16469311055c8164d2826c33-89958635.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983834-3032974025c8164daa16a60-19134316.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983835-9707405845c8164db1b6549-32330505.jpg",
        "http://localhost:8888/img/products/1000x1000/1551983835-15858453885c8164db9541f0-95756213.jpg"
      ],
      "id": 34008669085
    }
  ],
  "attributes": [
    {
      "id": "MODEL",
      "value_name": "Slim strappede"
    },
    {
      "id": "HEEL_TYPE",
      "value_id": "994260",
    },
    {
      "id": "RELEASE_YEAR",
      "value_name": "2019"
    },
    {
      "id": "FABRIC_DESIGN",
      "value_id": "508602",
    },
    {
      "id": "FOOTWEAR_STYLE",
      "value_id": "1006227",
    },
    {
      "id": "RELEASE_SEASON",
      "value_id": "994283",
    },
    {
      "id": "OUTSOLE_MATERIAL",
      "value_id": "930364",
    },
    {
      "id": "FOOTWEAR_MATERIAL",
      "value_id": "3993038",
    }
  ],
  "shipping": {
    "mode": "me2",
    "local_pick_up": false,
    "free_shipping": false,
    "free_methods": [],
    "dimensions": null,
    "tags": []
  },
  "status": "active"
}

 

Share this post


Link to post
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this