> For the complete documentation index, see [llms.txt](https://help.stockeo.solvenium.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.stockeo.solvenium.com/data-mapping/format/json.md).

# JSON

JSON is a data format commonly used by APIs.

<figure><img src="/files/YFPy22jSSdZiIUvGH3lC" alt=""><figcaption><p>JSON settings</p></figcaption></figure>

### Products List Path

The key information that Stockeo needs to know is where the list of products is located in a JSON structure.

#### Top level array - empty path

Very often the list of products is at the top level. You can recognize it by the fact that the JSON starts and ends with square brackets `[ ]`.

```json
[{
    "sku": "E0001",
    "qty": 12,
},{
   "sku": "E0002",
   "qty": 23,
}, ... ]
```

In such a case you can leave the Products List Path empty.

#### Object property

Sometime the list is placed under an object property. Then you need to specify the property name in the Products List Path.

```
{
    "total_count": 7532,
    "items": [{
            "sku": "E0001",
            "qty": 12,
        },{
           "sku": "E0002",
           "qty": 23,
        }, 
        ... 
     ]
}
```

For the example above, the Products List Path should be `items`.

#### Nested path

Rarely, the list of products may be nested within an inner object that involves traversing multiple levels of objects to reach the desired data. In such a case you need to specify the full path, that is, a list of properties separated by dots, without any spaces between them.

```
{
    "status": "success",
    "data": {
        "count": 7532
        "items": [{
                "sku": "E0001",
                "qty": 12,
            },{
               "sku": "E0002",
               "qty": 23,
            }, 
            ... 
        ]
    }
}
```

For the example above, the Products List Path should be `data.items`.

### Variants Path

Use this field only when product variants are nested within the main product object.

{% hint style="info" %}
If variants are defined as separate product objects and share a common value (such as product name, parent SKU, or parent ID), this field should remain empty.

For additional details, refer to the [Variants](https://help.stockeo.solvenium.com/data-mapping/variants) section.
{% endhint %}

```json
{
  "products": [
    {
      "id": 8237461928374,
      "title": "Basic T-Shirt",
      "variants": [
        {
          "id": 4839201746501,
          "title": "Black / M",
          "option1": "Black",
          "option2": "M",
          "option3": null,
          "sku": "TSHIRT-BLK-M",
          "price": "79.99"
        },
        {
          "id": 4839201746502,
          "title": "White / L",
          "option1": "White",
          "option2": "L",
          "option3": null,
          "sku": "TSHIRT-WHT-L",
          "price": "79.99"
        }
      ]
    }
  ]
}
```

For the JSON above, enter `variants` in the Variants Path field.

<figure><img src="/files/2rPmuuvpuHtQywivloe0" alt="Variants path settings for JSON feeds in Stockeo automation"><figcaption><p>Variants Path settings for JSON feeds in Stockeo</p></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://help.stockeo.solvenium.com/data-mapping/format/json.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
