API za potpuno ponovno indeksiranje

Posle obimnih izmena zamenite indeksirane podatke tako što ćete poslati sve proizvode, kategorije i atribute.

Poslednje ažuriranje:

Na ovoj stranici

Pregled

API za potpuno ponovno indeksiranje koristite kod obimnih izmena podataka. Telo zahteva mora da sadrži sve podatke o proizvodima, kategorijama i atributima, u skladu sa uputstvima za Athena XAI Datasource.

Endpoint

MetodaPutanja
POST/api/v1/open-api/reindex
POST/api/v2/open-api/reindex

Telo zahteva

JSON
{
   "token": "{{website_token}}", //required
   "data": {
      "categories": [ //required, array of objects
         {
            "id": "4",
            "parent_id": "3",
            "parent_name": "Gear",
            "level": "3",
            "name": "Bags",
            "image": null,
            "url": "http://magento.local.com/gear/bags.html",
            "path": "Gear > Bags",
            "category_size": 14,
            "is_anchor": "1"
         },
         {
            "id": "5",
            "parent_id": "3",
            "parent_name": "Gear",
            "level": "3",
            "name": "Fitness Equipment",
            "image": null,
            "url": "http://magento.local.com/gear/fitness-equipment.html",
            "path": "Gear > Fitness Equipment",
            "category_size": 11,
            "is_anchor": "1"
         }
         ...
      ],
      "attributes": [ //required, array of objects
         {
            "id": "93",
            "code": "color",
            "options": [
               {
                  "value": "49",
                  "label": "Black"
               },
               {
                  "value": "50",
                  "label": "Blue"
               }
            ]
         },
         {
            "id": "144",
            "code": "size",
            "options": [
               {
                  "value": "91",
                  "label": "55 cm"
               },
               {
                  "value": "166",
                  "label": "XS"
               }
            ]
         }
         ...
      ],
      "products": [ //required, array of objects
         {
            "entity_id": "1",
            "attribute_set_id": "15",
            "type_id": "simple",
            "sku": "24-MB01",
            "has_options": "0",
            "required_options": "0",
            "created_at": "2021-07-26 08:02:14",
            "updated_at": "2021-07-26 08:02:14",
            "visibility": "4",
            "status": "1",
            "name": "Joust Duffle Bag",
            "image": "http://magento.local.com/media/catalog/mb01-blue-0.jpg",
            "small_image": "/m/b/mb01-blue-0.jpg",
            "thumbnail": "/m/b/mb01-blue-0.jpg",
            "url_key": "joust-duffle-bag",
            "price": "32.000000",
            "description": ">The sporty Joust Duffle Bag can't be beat.",
            "store_id": 1,
            "total_reviews": 2,
            "reviews": 50,
            "link": "http://magento.local.com/joust-duffle-bag.html",
            "full_image_path": "http://magento.local.com/media/mb01-blue-0.jpg",
            "stock": 1,
            "categories": [
               "3",
               "4"
            ],
            "salable_qty": 100
         }
         ...
      ]
   }
}

Uspešan odgovor

JSON
{
   "message": "Reindex Successfully finished!"
}