Poniższy sposób integracji umożliwia pobranie danych i utworzenie własnego widgetu (pluginu).
URL wywołujący:
https://api.100shoppers.com/{your-plugin-Id}/buybox.json?{par}={value}
gdzie:
- {your-plugin-Id} –unikalny identyfikator pluginu do pobrania w panelu.
- {par} – parametr/y opisujący produkt
Parametry wymagane
number="{_product_GTIN_number_}"
sku="{_your_unique_manufacturer's_product ID_}"
name="{_your_products_name_}
category="{_the_category_path_of_your_product_}"
price="{_optional_product_suggested_retail_price_}"
source_url="{_page_URL_on__which_widget_is_displayed_}"
referer="{_page_referer_on_which_widget_is_displayed_}"
Parametry opcjonalne
alt="{_your_containerID_with_the_alternative_content_if_offers_are_not_avaibile_in_the_widget_}"
description="{_an_optional_product_short_description_}"
image"{_is_an_optional_product_image_URL_}"
abpar1, abpar2, abpar3="{_additional_abpar_parameters_passed_along_with_the_transaction_}"
Przykład
https://api.100shoppers.com/1/buybox.json?number={_GTIN_product_number}&source_url={_page_URL_on_which_widget_is_displayed}&referer={_page_referer_on_which_widget_is_displayed}
Przykład
https://api.100shoppers.com/1/buybox.json?number=8590669282227
Zwracane dane
{
"status":true,
"data":{
"https:\/\/buybox.click\/bbclick_903_23107592":{
"id":"23107592",
"price":"228.00",
"name":"euro.com.pl",
"icon":"https:\/\/buybox.click\/uploads\/campaign\/6e8c8c57854fe01ea5d6c379a0d255610fdd2ba0.png",
"logo":"https:\/\/buybox.click\/uploads\/campaign\/fc07cd2aa6cdeb9f2c3022c87e2fb2138e5b9a19.png",
"type":null,
"typeId":null,
"typeName":"",
"shopId":"152"
},
"https:\/\/go.buybox.click\/bbclick_903_23444116":{
"id":"23444116",
"price":"228.00",
"name":"mediaexpert.pl",
"icon":"https:\/\/buybox.click\/uploads\/campaign\/105e4bc27e08cdc6e7491708c72af2fa76bfbb49.png",
"logo":"https:\/\/buybox.click\/uploads\/campaign\/e67ead91b125d698c9af03dfbcdc3a7b7bda81ff.png",
"type":null,
"typeId":null,
"typeName":"",
"shopId":"139"
},
"https:\/\/go.buybox.click\/bbclick_903_46853379":{
"id":"46853379",
"price":"228.00",
"name":"Neonet.pl",
"icon":"https:\/\/buybox.click\/uploads\/campaign\/f84884d584ffeccf90812acda7e54e0126c32909.jpeg",
"logo":"https:\/\/buybox.click\/uploads\/campaign\/9338bf621e1a819b04b3fd648355651343090b81.png",
"type":null,
"typeId":null,
"typeName":"",
"shopId":"204"}},
"spaceId":3,
"trackingUrl":"https:\/\/utrack.buybox.click\/bb4publisher.js",
"useCSS":true,
"useTabs":false,
"defaultTab":0,
"rowCount":3
}
Ważne
Dla adresu URL produktu - do adresu URL zwracanego przez API należy dodać dwa parametry, gdzie:
bb_op="{_this_is_the_position_on_which_the_offer_is_displayed_}"
bb_oc="{_the_number_of_displayed_offers_}"
Przykład dla zapytania API dla adresu URL z powyższymi parametrami:
This is the example for an API request with the parameters specified in the URL:
https://go.buybox.click/bbclick_16342_183167581?bb_op=1&bb_oc=6
price="{_the_price_of_the_product_}"
name="{_the_name_of_the_shop_}"
icon="{_URL_address_of_the_shop_icon_}"
logo="{_URL_address_of_the_shop's_logotype}"
Inne sposoby implementacji widgetu:
- Dodanie skryptu w kodzie stony i tagu HTML
- Google Tag Manager