# Setting up a Worten API

{% hint style="info" %}
**UI update:** There is a new channel selection page and overview for **Feeds** and **Marketplaces** (previously called APIs)! Some visuals and instructions may not be up-to-date.&#x20;
{% endhint %}

Worten is a digital company, with 240 physical stores as well, that focuses on Portugal and Spain. They sell household appliances, IT products, telecommunications, sound & image, and entertainment, and they have invested, more recently, in offering toys, beauty, living & health, sport, books, home & decoration, DIY & garden, and even products for pets.

{% stepper %}
{% step %}

### Add a new Worten connection

The Worten API uses the Mirakl platform, which means you will need a Mirakl account to start sending your product listings to Worten.

When you have a Mirakl Worten account, go to "Connections > Add connection". Click on "+ Add a new connection" and you will see a screen, where you can select Worten. Fill in the label for your connection, for example, Worten. Then click on "Connect with Worten". You will be redirected to the environment where you can log in with your Mirakl credentials. After logging in, you will be redirected back to Channable where the connection will be available.

| [![Worten add connection.png](https://content.gitbook.com/content/F8GepmoSonQRG6RnHOxJ/blobs/qS7k0idbxNmv3qxOzy3Y/13880231501842)](https://helpcenter.channable.com/hc/article_attachments/13880231501842) | [![Mirakl API - Worten.png](https://content.gitbook.com/content/F8GepmoSonQRG6RnHOxJ/blobs/H6DtQzh3lM5W81aJ8gjf/21020603799314)](https://helpcenter.channable.com/hc/article_attachments/21020603799314) |
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| {% endstep %}                                                                                                                                                                                              |                                                                                                                                                                                                          |

{% step %}

### Add a new Worten API in Channable

Now go to the API's overview, in your project. Click on "+ Add new API", select the Worten connection you just made, and give your new API a name.

<figure><img src="https://content.gitbook.com/content/F8GepmoSonQRG6RnHOxJ/blobs/qyiGp9XRPIo7XO68Gejf/19237566972818" alt=""><figcaption></figcaption></figure>

Select the field you want to use for **Unique ID per item** (we recommend the 'id' field), and the **Language** in which you do categorizations and setup attributes. Click on "Continue" to finish creating the new Worten API.

{% hint style="warning" %}
Important: Worten has the option to define Sales Channels in our API. If you want to know more about channels, or about how to set this up, please follow the steps in [this article](https://helpcenter.channable.com/hc/en-us/articles/11883675662482). Setting up separate Worten APIs for different countries while using the same connection will not work, since those APIs will all overwrite each other.
{% endhint %}
{% endstep %}

{% step %}

### Create your product listings in Channable

Once you have created the Worten API, you can set up your product data by following the steps of the API.

{% stepper %}
{% step %}

#### Categories

For your product listings to be created, your products need a category. Add categories to your products by using the [generate categories feature](https://app.gitbook.com/s/u8whzIfip72Kvn3M1bsc/categorize-products/create-product-categories/use-the-generate-categories-function) or [create new categories from scratch](https://app.gitbook.com/s/u8whzIfip72Kvn3M1bsc/categorize-products/create-product-categories/add-categories-manually).
{% endstep %}

{% step %}

#### Rules

Create [different rules](https://app.gitbook.com/s/u8whzIfip72Kvn3M1bsc/rules-bulk-edit-and-enrich/using-rules) to optimize your products listings.&#x20;
{% endstep %}

{% step %}

#### Build - Shared attributes

Shared attributes are attributes that apply across all your items, like price and stock.&#x20;

1. Start by mapping fields to attributes marked as required by the marketplace.
2. Check the remaining attributes and map fields to ones relevant for your business.
3. Click **Save**.
   {% endstep %}

{% step %}

#### Build - Attributes per category

Category attributes are attributes that apply to items from specific categories, like battery information for electronic items, or sizing information for clothing.

1. Start by mapping fields to attributes marked as required by the marketplace.
2. Check the remaining attributes and map fields to ones relevant for your business.
3. Click **Save**.
   {% endstep %}
   {% endstepper %}

{% hint style="warning" %}
Compared to other Mirakl APIs, Worten does not have a 'title' in the build step. There is a “Product Name Pt” which is set to mandatory by Worten and “Product Name Es” in the Attributes step of the API. The description for both languages does have to be filled in the build step.
{% endhint %}

{% hint style="success" %}
**Tip:** Hover over <i class="fa-circle-question">:circle-question:</i> for more information on specific field requirements.
{% endhint %}

{% stepper %}
{% step %}
In the build step, you can also find the Sales channels tab where you can fill in your pricing information for each separate sales channel on Worten. More information about these Sales channels can be found here: [setting-up-mirakl-sales-channels](https://helpcenter.channable.com/list-advertise/sell-on-marketplaces/mirakl-marketplaces/setting-up-mirakl-sales-channels "mention")
{% endstep %}
{% endstepper %}
{% endstep %}

{% step %}

### GPSR and DSA requirements

The European Union (EU) has introduced new [GPSR and DSA requirements](https://helpcenter.channable.com/list-advertise/sell-on-marketplaces/get-started-with-marketplaces/what-you-need-to-do-to-be-gpsr-and-dsa-compliant) for online platforms, including marketplaces.

For your Worten API in Channable, make sure to fill in the category-specific **Attributes per category** tab in the **Build** step:

* **Email Address Of The Person Responsible In The Eu:** Enter the email address of the person responsible in the EU.
* **Postal Address Of The Person Responsible In The Eu:** Provide the postal address of the person responsible in the EU.
* **Name Of Person Responsible In The Eu:** Enter the name of the person responsible in the EU.

{% hint style="info" %}
These attributes are required to comply with EU GPSR and DSA marketplace obligations.
{% endhint %}
{% endstep %}

{% step %}

### Send your products to Worten

Almost there, your product listings are ready to be sent. If you have not activated your project, go to your project settings on the left-hand side of the screen and click 'activate project'. After, go back to the APIs overview and go to "Your Worten API Name > Settings," where you activate the API by selecting "Activate API". After you have completed this step, navigate back to the APIs overview and select the blue "Run now" button to send your product listings to Worten.
{% endstep %}

{% step %}

### Check your product listings for errors

After you have sent your product listings to Worten, go to the Results tab of your Worten API. Click in the filter on 'error'. Now you can see which product listings have errors and are not placed. Click on a specific error to see more information on what is causing the error. If you have solved some errors by changing the settings or product information, re-run the Worten API to see the new results.
{% endstep %}
{% endstepper %}

### Best practices

{% hint style="info" %}
Adding multiple attribute values: When adding multiple values in an attribute field for Mirakl Marketplaces, separate each value with a pipe symbol "|" to ensure proper detection and processing.
{% endhint %}

{% hint style="info" %}
Seller's Product ID for single/simple products: There are two attributes named 'SellerArticleId' and 'SellerProductId'. 'SellerProductId' refers to the Parent ID, while 'SellerArticleId' refers to the variant items. For single products, both attributes must be filled with the same value.
{% endhint %}

For more information on Mirakl Marketplace errors, how-to's, and best practices, check out [mirakl-guide-settings-and-solutions](https://helpcenter.channable.com/list-advertise/sell-on-marketplaces/mirakl-marketplaces/mirakl-guide-settings-and-solutions "mention")
