Integracja Mirakl z BigQuery

Połącz marketplace oparty na Mirakl z BigQuery w WitCloud - zamówienia, oferty, transakcje, zwroty i dane sklepu sprzedawcy pobierane za pomocą klucza API sprzedawcy.

Aktualizacja

Wprowadzenie

Ta integracja pobiera dane Twojego sklepu sprzedawcy na marketplace'ie opartym na Mirakl (na przykład Empik, Decathlon czy Leroy Merlin) przez Mirakl Seller API i zapisuje je w Google Cloud BigQuery. Dostajesz zamówienia wraz z pozycjami, oferty, linie transakcji (prowizje, opłaty, zwroty i wypłaty), zwroty oraz dane Twojego sklepu. Dzięki temu możesz analizować sprzedaż na marketplace'ie razem z innymi danymi.

Konfiguracja

Wykonaj poniższe kroki, aby połączyć Mirakl z BigQuery. Po zakończeniu konfiguracji dane z marketplace'u będą automatycznie trafiać do Twojego projektu BigQuery.

Potrzebujesz adresu instancji Mirakl Twojego marketplace'u (podanego przez jego operatora, na przykład https://your-marketplace.mirakl.net) oraz klucza API z panelu sprzedawcy marketplace'u. Klucz generujesz tam, w interfejsie Mirakl, a nie w WitCloud.

Konfiguracja modułu

Wejdź w menu do Integracje i kliknij Dodaj integrację.

Lista integracji z przyciskiem Dodaj integrację

Wybierz Mirakl z listy dostępnych integracji.

Katalog integracji zawężony do Mirakl

Wpisz Nazwę źródła danych, na przykład „Mirakl PL". Dobra nazwa pomoże Ci później rozpoznać źródło danych.

Pole Nazwa źródła danych wypełnione przykładową nazwą Mirakl PL

Wpisz Adres instancji Mirakl, czyli adres instancji Mirakl Twojego marketplace'u. Musi zaczynać się od https://. Ukośnik na końcu lub /api są usuwane automatycznie.

Pole Adres instancji Mirakl wypełnione przykładowym adresem https://your-marketplace.mirakl.net

Autoryzacja

Jeśli klucz API dla tego marketplace'u został już dodany, wybierz go z listy Autoryzacja Mirakl i pomiń resztę tego kroku.

Kliknij Autoryzuj. Przycisk jest nieaktywny, dopóki w polu Adres instancji Mirakl nie ma poprawnego adresu, ponieważ klucz jest sprawdzany w tej instancji.

Przycisk Autoryzuj obok pola Autoryzacja Mirakl, aktywny po wpisaniu adresu instancji

W oknie Autoryzuj wklej Klucz API wygenerowany w panelu sprzedawcy marketplace'u, w ustawieniach Twojego użytkownika, i kliknij Utwórz. Klucz jest ukryty podczas wpisywania. Klucz mogą dodawać tylko osoby z rolą Edytor lub wyższą.

Okno Autoryzuj z polem Klucz API wypełnionym przykładową wartością

WitCloud od razu sprawdza klucz. Jeśli zostanie odrzucony, zobaczysz powód: klucz jest nieprawidłowy, nie ma wystarczających uprawnień, instancja jest nieosiągalna albo adres nie wskazuje na Mirakl Seller API.

Zapisany klucz pojawia się na liście Autoryzacja Mirakl. Jest opisany nazwą sklepu, adresem instancji i początkiem klucza, dzięki czemu odróżnisz od siebie kilka kluczy. Wybierz ten, którego chcesz użyć.

Otwarta lista Autoryzacja Mirakl z jednym przykładowym kluczem

Dane są pobierane dla sklepu, do którego należy klucz API, więc nie wybierasz sklepu. Aby pobierać dane z kilku sklepów lub marketplace'ów, dodaj osobny klucz i osobną integrację dla każdego z nich.

Ustawienia zaawansowane

Kliknij Pokaż ustawienia zaawansowane, aby dostosować:

  • Odświeżanie danych (oferty, sklep): co ile godzin odświeżana jest tabela ofert. Minimum 4, maksimum 12, domyślnie 4. Tabela sklepu jest odświeżana raz dziennie, niezależnie od tej wartości.

Otwarte ustawienia zaawansowane z polem Odświeżanie danych (oferty, sklep) ustawionym na 4 godziny

  • Stały adres IP: po włączeniu wszystkie zapytania są wysyłane ze stałego adresu IP 34.118.32.227, który możesz przekazać operatorowi marketplace'u, aby dodał go do listy dozwolonych adresów.

Przełącznik Stały adres IP w ustawieniach zaawansowanych

  • Tabele do pobrania: zawęź tabele, jeśli nie potrzebujesz wszystkich. Domyślnie zaznaczone jest wszystkie pięć (zamówienia, oferty, transakcje, zwroty i sklep), a co najmniej jedna musi pozostać zaznaczona.

Pole Tabele do pobrania z wybranymi wszystkimi pięcioma oferowanymi tabelami

Kliknij Dalej, aby przejść do ustawień pobierania danych.

Wypełnione ustawienia źródła danych z przyciskiem Dalej

Dane historyczne i harmonogram

W polu Dane historyczne wpisz liczbę dni danych historycznych do pobrania, maksymalnie 365.

Pole Dane historyczne wypełnione wartością 365 dni

Harmonogram synchronizacji danych zostanie utworzony automatycznie. Więcej informacji na ten temat znajdziesz tutaj.

Kliknij Utwórz, aby zakończyć konfigurację.

Ustawienia pobierania danych z przyciskiem Utwórz

Gotowe! Dane z Mirakl będą teraz synchronizowane z BigQuery zgodnie z utworzonym harmonogramem.

Synchronizacja danych

Zamówienia, linie transakcji i zwroty są pobierane według daty ich utworzenia. Ostatnie dni są pobierane ponownie przy kolejnych uruchomieniach, więc zmiany statusów, zwroty środków i stany płatności z mniej więcej ostatnich 30 dni zostaną uwzględnione. Oferty i sklep to zdjęcia bieżącego stanu, zapisywane w dniu uruchomienia: aby odczytać aktualne wartości, użyj najnowszego dnia.

Transakcje i zwroty zależą od opcjonalnych modułów Mirakl. Jeśli operator marketplace'u nie włączył płatności sprzedawcy lub zwrotów, odpowiednia tabela pozostaje pusta.

Schemat danych

Rozwiń poniższe tabele, aby zobaczyć pełny schemat danych pobieranych z Mirakl. Klienci są ograniczeni do identyfikatora, ustawień regionalnych oraz miasta, kodu pocztowego, regionu i kraju ich adresów. Imiona i nazwiska, ulice, numery telefonów i adresy e-mail nie są pobierane.

Schemat danych tabeli mirakl_orders
Field NameModeType
order_idNULLABLESTRING
commercial_idNULLABLESTRING
created_dateNULLABLETIMESTAMP
last_updated_dateNULLABLETIMESTAMP
acceptance_decision_dateNULLABLETIMESTAMP
customer_debited_dateNULLABLETIMESTAMP
shipping_deadlineNULLABLETIMESTAMP
transaction_dateNULLABLETIMESTAMP
transaction_numberNULLABLESTRING
order_stateNULLABLESTRING
order_state_reason_codeNULLABLESTRING
order_state_reason_labelNULLABLESTRING
currency_iso_codeNULLABLESTRING
order_tax_modeNULLABLESTRING
priceNULLABLEFLOAT
shipping_priceNULLABLEFLOAT
total_priceNULLABLEFLOAT
total_commissionNULLABLEFLOAT
fully_refundedNULLABLEBOOLEAN
has_incidentNULLABLEBOOLEAN
has_invoiceNULLABLEBOOLEAN
customer_directly_pays_sellerNULLABLEBOOLEAN
payment_typeNULLABLESTRING
payment_workflowNULLABLESTRING
payment_durationNULLABLEINTEGER
quote_idNULLABLESTRING
channelNULLABLERECORD
channel.codeNULLABLESTRING
channel.labelNULLABLESTRING
referencesNULLABLERECORD
references.order_reference_for_customerNULLABLESTRING
references.order_reference_for_sellerNULLABLESTRING
customerNULLABLERECORD
customer.customer_idNULLABLESTRING
customer.localeNULLABLESTRING
customer.billing_addressNULLABLERECORD
customer.billing_address.cityNULLABLESTRING
customer.billing_address.zip_codeNULLABLESTRING
customer.billing_address.stateNULLABLESTRING
customer.billing_address.countryNULLABLESTRING
customer.billing_address.country_iso_codeNULLABLESTRING
customer.shipping_addressNULLABLERECORD
customer.shipping_address.cityNULLABLESTRING
customer.shipping_address.zip_codeNULLABLESTRING
customer.shipping_address.stateNULLABLESTRING
customer.shipping_address.countryNULLABLESTRING
customer.shipping_address.country_iso_codeNULLABLESTRING
shipping_type_codeNULLABLESTRING
shipping_type_labelNULLABLESTRING
shipping_type_standard_codeNULLABLESTRING
shipping_zone_codeNULLABLESTRING
shipping_zone_labelNULLABLESTRING
shipping_carrier_codeNULLABLESTRING
shipping_carrier_standard_codeNULLABLESTRING
shipping_companyNULLABLESTRING
delivery_dateNULLABLERECORD
delivery_date.earliestNULLABLETIMESTAMP
delivery_date.latestNULLABLETIMESTAMP
fulfillmentNULLABLERECORD
fulfillment.centerNULLABLERECORD
fulfillment.center.codeNULLABLESTRING
promotionsNULLABLERECORD
promotions.total_deduced_amountNULLABLEFLOAT
order_taxesREPEATEDRECORD
order_taxes.codeNULLABLESTRING
order_taxes.rateNULLABLEFLOAT
order_taxes.total_amountNULLABLEFLOAT
order_linesREPEATEDRECORD
order_lines.order_line_idNULLABLESTRING
order_lines.order_line_indexNULLABLEINTEGER
order_lines.order_line_stateNULLABLESTRING
order_lines.order_line_state_reason_codeNULLABLESTRING
order_lines.order_line_state_reason_labelNULLABLESTRING
order_lines.offer_idNULLABLEINTEGER
order_lines.offer_skuNULLABLESTRING
order_lines.offer_state_codeNULLABLESTRING
order_lines.product_skuNULLABLESTRING
order_lines.product_shop_skuNULLABLESTRING
order_lines.product_titleNULLABLESTRING
order_lines.category_codeNULLABLESTRING
order_lines.category_labelNULLABLESTRING
order_lines.quantityNULLABLEINTEGER
order_lines.price_unitNULLABLEFLOAT
order_lines.origin_unit_priceNULLABLEFLOAT
order_lines.priceNULLABLEFLOAT
order_lines.shipping_priceNULLABLEFLOAT
order_lines.total_priceNULLABLEFLOAT
order_lines.commission_feeNULLABLEFLOAT
order_lines.total_commissionNULLABLEFLOAT
order_lines.commission_taxesREPEATEDRECORD
order_lines.commission_taxes.codeNULLABLESTRING
order_lines.commission_taxes.rateNULLABLEFLOAT
order_lines.commission_taxes.amountNULLABLEFLOAT
order_lines.taxesREPEATEDRECORD
order_lines.taxes.codeNULLABLESTRING
order_lines.taxes.rateNULLABLEFLOAT
order_lines.taxes.amountNULLABLEFLOAT
order_lines.shipping_taxesREPEATEDRECORD
order_lines.shipping_taxes.codeNULLABLESTRING
order_lines.shipping_taxes.rateNULLABLEFLOAT
order_lines.shipping_taxes.amountNULLABLEFLOAT
order_lines.feesREPEATEDRECORD
order_lines.fees.codeNULLABLESTRING
order_lines.fees.amountNULLABLEFLOAT
order_lines.promotionsREPEATEDRECORD
order_lines.promotions.idNULLABLESTRING
order_lines.promotions.deduced_amountNULLABLEFLOAT
order_lines.promotions.offered_quantityNULLABLEINTEGER
order_lines.promotions.promo_codeNULLABLESTRING
order_lines.created_dateNULLABLETIMESTAMP
order_lines.debited_dateNULLABLETIMESTAMP
order_lines.shipped_dateNULLABLETIMESTAMP
order_lines.received_dateNULLABLETIMESTAMP
order_lines.last_updated_dateNULLABLETIMESTAMP
order_lines.refundsREPEATEDRECORD
order_lines.refunds.idNULLABLESTRING
order_lines.refunds.amountNULLABLEFLOAT
order_lines.refunds.shipping_amountNULLABLEFLOAT
order_lines.refunds.quantityNULLABLEINTEGER
order_lines.refunds.commission_amountNULLABLEFLOAT
order_lines.refunds.commission_total_amountNULLABLEFLOAT
order_lines.refunds.commission_taxesREPEATEDRECORD
order_lines.refunds.commission_taxes.codeNULLABLESTRING
order_lines.refunds.commission_taxes.rateNULLABLEFLOAT
order_lines.refunds.commission_taxes.amountNULLABLEFLOAT
order_lines.refunds.taxesREPEATEDRECORD
order_lines.refunds.taxes.codeNULLABLESTRING
order_lines.refunds.taxes.rateNULLABLEFLOAT
order_lines.refunds.taxes.amountNULLABLEFLOAT
order_lines.refunds.shipping_taxesREPEATEDRECORD
order_lines.refunds.shipping_taxes.codeNULLABLESTRING
order_lines.refunds.shipping_taxes.rateNULLABLEFLOAT
order_lines.refunds.shipping_taxes.amountNULLABLEFLOAT
order_lines.refunds.reason_codeNULLABLESTRING
order_lines.refunds.created_dateNULLABLETIMESTAMP
order_lines.refunds.order_refund_idNULLABLESTRING
order_lines.refunds.refund_stateNULLABLESTRING
order_lines.refunds.transaction_dateNULLABLETIMESTAMP
order_lines.refunds.transaction_numberNULLABLESTRING
order_lines.cancelationsREPEATEDRECORD
order_lines.cancelations.idNULLABLESTRING
order_lines.cancelations.amountNULLABLEFLOAT
order_lines.cancelations.shipping_amountNULLABLEFLOAT
order_lines.cancelations.quantityNULLABLEINTEGER
order_lines.cancelations.commission_amountNULLABLEFLOAT
order_lines.cancelations.commission_total_amountNULLABLEFLOAT
order_lines.cancelations.commission_taxesREPEATEDRECORD
order_lines.cancelations.commission_taxes.codeNULLABLESTRING
order_lines.cancelations.commission_taxes.rateNULLABLEFLOAT
order_lines.cancelations.commission_taxes.amountNULLABLEFLOAT
order_lines.cancelations.taxesREPEATEDRECORD
order_lines.cancelations.taxes.codeNULLABLESTRING
order_lines.cancelations.taxes.rateNULLABLEFLOAT
order_lines.cancelations.taxes.amountNULLABLEFLOAT
order_lines.cancelations.shipping_taxesREPEATEDRECORD
order_lines.cancelations.shipping_taxes.codeNULLABLESTRING
order_lines.cancelations.shipping_taxes.rateNULLABLEFLOAT
order_lines.cancelations.shipping_taxes.amountNULLABLEFLOAT
order_lines.cancelations.reason_codeNULLABLESTRING
order_lines.cancelations.created_dateNULLABLETIMESTAMP
Schemat danych tabeli mirakl_offers
Field NameModeType
offer_idNULLABLEINTEGER
shop_skuNULLABLESTRING
product_skuNULLABLESTRING
product_titleNULLABLESTRING
product_brandNULLABLESTRING
product_tax_codeNULLABLESTRING
product_referencesREPEATEDRECORD
product_references.referenceNULLABLESTRING
product_references.reference_typeNULLABLESTRING
category_codeNULLABLESTRING
category_labelNULLABLESTRING
currency_iso_codeNULLABLESTRING
priceNULLABLEFLOAT
total_priceNULLABLEFLOAT
msrpNULLABLEFLOAT
applicable_pricingNULLABLERECORD
applicable_pricing.priceNULLABLEFLOAT
applicable_pricing.unit_origin_priceNULLABLEFLOAT
applicable_pricing.unit_discount_priceNULLABLEFLOAT
applicable_pricing.discount_start_dateNULLABLETIMESTAMP
applicable_pricing.discount_end_dateNULLABLETIMESTAMP
quantityNULLABLEINTEGER
min_quantity_alertNULLABLEINTEGER
min_order_quantityNULLABLEINTEGER
max_order_quantityNULLABLEINTEGER
package_quantityNULLABLEINTEGER
state_codeNULLABLESTRING
activeNULLABLEBOOLEAN
inactivity_reasonsREPEATEDSTRING
channelsREPEATEDSTRING
favorite_rankNULLABLEINTEGER
leadtime_to_shipNULLABLEINTEGER
shipping_deadlineNULLABLETIMESTAMP
min_shipping_priceNULLABLEFLOAT
min_shipping_price_additionalNULLABLEFLOAT
min_shipping_typeNULLABLESTRING
min_shipping_zoneNULLABLESTRING
available_start_dateNULLABLETIMESTAMP
available_end_dateNULLABLETIMESTAMP
Schemat danych tabeli mirakl_transactions
Field NameModeType
idNULLABLESTRING
typeNULLABLESTRING
amountNULLABLEFLOAT
amount_creditedNULLABLEFLOAT
amount_debitedNULLABLEFLOAT
balanceNULLABLEFLOAT
psp_balanceNULLABLEFLOAT
currency_iso_codeNULLABLESTRING
date_createdNULLABLETIMESTAMP
last_updatedNULLABLETIMESTAMP
payment_stateNULLABLESTRING
pay_out_psp_codeNULLABLESTRING
seller_billing_cycle_idNULLABLESTRING
accounting_document_idNULLABLESTRING
accounting_document_numberNULLABLESTRING
accounting_document_creation_dateNULLABLETIMESTAMP
entitiesNULLABLERECORD
entities.domainNULLABLESTRING
entities.orderNULLABLERECORD
entities.order.idNULLABLESTRING
entities.order.commercial_idNULLABLESTRING
entities.order.creation_dateNULLABLETIMESTAMP
entities.order.referencesNULLABLERECORD
entities.order.references.order_reference_for_customerNULLABLESTRING
entities.order.references.order_reference_for_sellerNULLABLESTRING
entities.order_lineNULLABLERECORD
entities.order_line.idNULLABLESTRING
entities.refundNULLABLERECORD
entities.refund.idNULLABLESTRING
entities.shipmentNULLABLERECORD
entities.shipment.idNULLABLESTRING
entities.debitNULLABLERECORD
entities.debit.idNULLABLESTRING
entities.channelNULLABLERECORD
entities.channel.codeNULLABLESTRING
entities.feeNULLABLERECORD
entities.fee.codeNULLABLESTRING
entities.order_feeNULLABLERECORD
entities.order_fee.codeNULLABLESTRING
entities.order_taxNULLABLERECORD
entities.order_tax.codeNULLABLESTRING
entities.order_tax.rateNULLABLEFLOAT
entities.shop_taxNULLABLERECORD
entities.shop_tax.codeNULLABLESTRING
entities.shop_tax.rateNULLABLEFLOAT
entities.transaction_infoNULLABLERECORD
entities.transaction_info.dateNULLABLETIMESTAMP
entities.transaction_info.numberNULLABLESTRING
Schemat danych tabeli mirakl_returns
Field NameModeType
idNULLABLESTRING
rmaNULLABLESTRING
stateNULLABLESTRING
order_idNULLABLESTRING
order_commercial_idNULLABLESTRING
reason_codeNULLABLESTRING
rejection_reason_codeNULLABLESTRING
method_codeNULLABLESTRING
date_createdNULLABLETIMESTAMP
last_updatedNULLABLETIMESTAMP
return_addressNULLABLERECORD
return_address.cityNULLABLESTRING
return_address.zip_codeNULLABLESTRING
return_address.stateNULLABLESTRING
return_address.country_iso_codeNULLABLESTRING
return_linesREPEATEDRECORD
return_lines.order_line_idNULLABLESTRING
return_lines.quantityNULLABLEINTEGER
return_lines.reason_codeNULLABLESTRING
trackingNULLABLERECORD
tracking.carrier_codeNULLABLESTRING
tracking.carrier_nameNULLABLESTRING
tracking.carrier_standard_codeNULLABLESTRING
Schemat danych tabeli mirakl_shop
Field NameModeType
shop_idNULLABLEINTEGER
shop_nameNULLABLESTRING
shop_stateNULLABLESTRING
suspension_typeNULLABLESTRING
currency_iso_codeNULLABLESTRING
modelNULLABLESTRING
shipping_countryNULLABLESTRING
channelsREPEATEDSTRING
is_professionalNULLABLEBOOLEAN
premiumNULLABLEBOOLEAN
free_shippingNULLABLEBOOLEAN
gradeNULLABLEFLOAT
approval_rateNULLABLEFLOAT
approval_delayNULLABLEINTEGER
evaluations_countNULLABLEINTEGER
offers_countNULLABLEINTEGER
orders_countNULLABLEINTEGER
order_messages_response_delayNULLABLEINTEGER
date_createdNULLABLETIMESTAMP
last_updated_dateNULLABLETIMESTAMP
closed_fromNULLABLETIMESTAMP
closed_toNULLABLETIMESTAMP
payment_detailsNULLABLERECORD
payment_details.paid_balanceNULLABLEFLOAT
payment_details.payable_balanceNULLABLEFLOAT
payment_details.pending_balanceNULLABLEFLOAT
payment_details.reserve_balanceNULLABLEFLOAT
payment_details.reserve_targetNULLABLEFLOAT