# Query Synchronization and Production Errors

This guide will explain how to consult products that have had errors connecting in B2W and also production errors after the connection. You will also be able to query orders synchronization errors.

### List error categories

Performing the query below will list all error categories in SkyHub.

```
https://api.skyhub.com.br/sync_errors/categories
```

![](/files/-LWlzZY_H1P-kshYsRon)

![](/files/-LWlzbLofdTV1kNqK6j8)

The **code** field of the query above refers to error category, such as *"**link\_b2w\_products**".*

### Get an error category

In this query you can get all errors and solutions mapped to a particular category as an example we will use the error category *"link\_b2w\_product".*

```
https://api.skyhub.com.br/sync_errors/categories/link_b2w_products
```

![](/files/-LWm11dD1k89J3vXaCXb)

![](/files/-LWm13hjgUzwqHdqU-hj)

### Get products with error

In the query below you will be able to obtain all your products that you encounter with any type of error.

```
https://api.skyhub.com.br/sync_errors/products
```

![](/files/-LWm3q3OzuCsEPLKb3tj)

![](/files/-LWm3tetNBoNb_d_x_rB)

| Field                     | Description                                       |
| ------------------------- | ------------------------------------------------- |
| **error\_qty**            | total of products with error                      |
| **entity\_id**            | SKU number with error                             |
| **message**               | error message                                     |
| **last\_accurence**       | date of the last error occurrence of this product |
| **error\_code**           | error code                                        |
| **error\_category\_code** | error category code                               |

### Get products with error by category:

The example below will only return products with an error of a given category. In this case we will continue to use the example error category *"link\_b2w\_products"* to create a query.

```
https://api.skyhub.com.br/sync_errors/products?error_category_code=link_b2w_products
```

![](/files/-LWm7Rvap_k9GlPVFnde)

The query returns the total of products with error for the category chosen in the query and also its sku and error.

![](/files/-LWm7V1HQ58Vov7yS-0b)

### Get orders with errors

In the query below you will be able to get all of your orders that are with any type of error.

```
https://api.skyhub.com.br/sync_errors/orders
```

![](/files/-LWm8imndFbd8ebgy3Hm)

This query will return with the total of failed orders, their delivery, and reason for the error.

![](/files/-LWm8nqpzGsgm_55hqej)

### Get orders with error by error category

```
https://api.skyhub.com.br/sync_errors/orders?error_category_code=sync_order_skyhub_to_mtkp 
```

![](/files/-LWmCLrB-waOtxXsrf-a)

![](/files/-LWmCOOUG3hG_EbsI7x6)

### Ignore product and order errors

#### Products:

When we use the "PATCH" method, we inform Skyhub that we do not want to see that particular error again, this mean, after correcting the problem, you can inform SkyHub that you have made the correction and do not want to see that error again, and it will not appear again.

```
PATCH /sync_errors/products
```

![](/files/-LWmCnjcdH00ibt_a7Wh)

#### Orders:

```
PATCH /sync_errors/orders
```

![](/files/-LWmD1vUPUYkCVal-WwM)

{% hint style="info" %}
If you have any question, please send an e-mail to **<api@skyhub.com.br>**
{% endhint %}


---

# Agent Instructions: 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:

```
GET https://skyhub-english.gitbook.io/skyhub-api-english/skyhub-api-guides/query-synchronization-and-production-errors.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
