Related Products - ''Frequently Bought Together''

Good morning everyone,
I’m reaching out to clarify a question related to the products API. I’d like to know if there is any field available in the API that allows me to pass information about associated products. For example, when accessing a specific product on our site for purchase, I noticed that the “Buy Together” section displays random products. However, I’d like it to show more accurately related products instead.

For example, when selecting a bottle of hydrogen peroxide, I’d like the associated products section to display items such as cotton and nail polish, providing a more coherent experience for our customers.

I noticed that when exporting products on the platform, there is a field called “Show_Together” — is that the field I should use to pass the associated products? If so, which API should I use?

I appreciate your attention in advance and look forward to your guidance on how to proceed.

Good afternoon, @HigorDev! How’s everything going?

This can be done through the Create SKU complement API via the ComplementTypeId field:

Karina Mota
Field Software Engineer | VTEX

Good morning,
I created a service to send the post via API.
url: https://dannycosmeticos.vtexcommercestable.com.br/api/catalog/pvt/skucomplement

body: {
“SkuId”: 277622,
“ParentSkuId”: 49719,
“ComplementTypeId”: 2
}

However, I noticed that product 277622 (hydrogen peroxide) did not associate with product 49719 (cotton). It didn’t show up on the site and when I extracted the product data from VTEX, the _ShowTogether row did not include product 49719.

The post returned OK but it wasn’t created in ShowTogether.
Attachment:

Hey @HigorDev, how’s it going?

Shouldn’t ComplementTypeId have the value 5 since it’s a ShowTogether relationship?

Good afternoon @andremiani, all good and you?
I made the change and set the post to 5, but it still hasn’t shown up, I’ll leave my post below as I sent it.

{
“SkuId”: 277622,
“ParentSkuId”: 49719,
“ComplementTypeId”: 5
}

Hmm… It didn’t work? How long did you wait for the new export to generate?
Could there be some kind of cache before it reflects in the exported file?

Good morning André, how’s it going? So it didn’t work out — I just tried it through Postman to check, and it even returns that it was already inserted. But in the export spreadsheet the associated product still doesn’t show up. On the site the product isn’t showing up either.
Check out the screenshot.

Good afternoon,
is there any other way?

Best regards,

Good morning,
I don’t think this ‘functionality’ works, does it!?

Hi @HigorDev, to do the front-end rendering, do you customize it by querying the API you mentioned?

Hey @HigorDev, did you manage to somehow display products in the “buy together” feature? I have the same component installed in my store and we’ve never been able to edit those products.

Has anyone managed to get the Buy Together feature working??? I’m using VTEX FASTSTORE here