コンテンツにスキップ

Shopifyのデータ機能

この記事では、BrazeのShopify機能の概要を説明します。トラッキング対象のShopifyデータやペイロード例、履歴バックフィル、製品の同期について取り上げます。

追跡されるShopifyイベント

Shopify統合では、e コマースの推奨イベントを使用して主要な購買行動を取得します。これらのイベントを使用した実装例やマーケティング戦略については、e コマースのユースケースを参照してください。

{
    "name": "ecommerce.product_viewed",
    "properties": {
        "product_id": "12345",
        "product_name": "product",
        "variant_id": "123",
        "image_url": "www.image-url.com",
        "product_url": "mystorefront.myshopify.com/product",
        "price": 10,
        "currency": "USD",
        "source": "mystorefront.myshopify.com",
        "metadata": {
          "sku": "sku"
        },
        "type": [
          "price_drop",
          "back_in_stock"
        ]
    }
}
{
    "name": "ecommerce.cart_updated",
    "properties": {
        "cart_id": "Z2NwLXVzLWVhc3QxOjAxSjk3UFg4RlFZMjVTVkRHRlc1RlI3SlRY",
        "currency": "USD",
        "total_value": 2000000,
        "products": [
            {
                "product_id": "8266836345064",
                "product_name": "PANTS!!!",
                "variant_id": "44610569208040",
                "image_url": "https://cdn.shopify.com/s/files/1/0604/4211/6328/files/1200px-Trousers-colourisolated.jpg?v=1689256168",
                "product_url": "https://test-store.myshopify.com/products/pants?variant=44610569208040",
                "quantity": 2,
                "price": 1000000,
                "metadata": {
                    "sku": "007"
                }
            }
        ],
        "source": "https://test-store.myshopify.com",
        "metadata": {}
    }
}
{
    "name": "ecommerce.checkout_started",
    "time": "2022-05-23T13:52:38-04:00",
    "properties": {
        "cart_id": "eeafa272cebfd4b22385bc4b645e762c",
        "total_value": 421.88,
        "subtotal_value": 396.88,
        "tax": 15.00,
        "shipping": 10.00,
        "currency": "USD",
        "products": [
            {
                "product_id": "632910392",
                "product_name": "IPod Nano - 8GB",
                "variant_id": "808950810",
                "quantity": 1,
                "price": 199,
                "metadata": {
                    "sku": "IPOD2008PINK"
                }
            }
        ],
        "source": "braze-mock-storefront.myshopify.com",
        "checkout_id": "123123123",
        "metadata": {
            "checkout_url": "https://checkout.local/548380009/checkouts/123123123/recover?key=example-secret-token"
        }
    }
}
{
    "name": "ecommerce.order_placed",
    "time": "2022-05-23T13:52:38-04:00",
    "properties": {
        "order_id": "820982911946154508",
        "cart_id": "eeafa272cebfd4b22385bc4b645e762c",
        "total_value": 421.88,
        "subtotal_value": 396.88,
        "tax": 15.00,
        "shipping": 10.00,
        "currency": "USD",
        "total_discounts": 5,
        "discounts": [],
        "products": [
            {
                "product_id": "632910392",
                "product_name": "IPod Nano - 8GB",
                "variant_id": "808950810",
                "quantity": 1,
                "price": 199,
                "metadata": {
                    "sku": "IPOD2008PINK"
                }
            }
        ],
        "source": "braze-mock-storefront.myshopify.com",
        "metadata": {
            "order_status_url": "https://apple.myshopify.com/690933842/orders/123456abcd/authenticate?key=abcdefg",
            "order_number": "1234",
            "tags": [
                "heavy",
                "heavy2"
            ],
            "referring_site": "https://www.google.com",
            "payment_gateway_names": [
                "visa",
                "bogus"
            ]
        }
    }
}
{
 "name": "shopify_fulfilled_order",
 "time": "2022-05-23T14:44:34-04:00",
 "properties": {
   "order_id": 4444668657855,
   "line_items": [
     {
       "quantity": 1,
       "product_id": 6143032066239,
       "sku": null,
       "title": "Dark Denim Top",
  "variant_id": 40094740549876,
       "variant_title": "Small Dark Denim Top",


       "vendor": "partners-demo",
       "name": "Dark Denim Top",
       "properties": [],
       "price": "60.00",
       "fulfillment_status": "fulfilled"
     }
   ],
   "shipping": [
     {
       "title": "Standard",
       "price": "0.00"
     }
   ],
   "total_price": "130.66",
   "confirmed": true,
   "total_discounts": "0.00",
   "discount_codes": [],
   "order_number": 1093,
   "order_status_url": "https://test-store.myshopify.com/",
   "cancelled_at": null,
   "tags": "",
   "closed_at": "2022-05-23T14:44:34-04:00",
   "fulfillment_status": "fulfilled",
   "fulfillments": [
     {
       "shipment_status": null,
       "status": "success",
       "tracking_company": "Other",
       "tracking_number": "456",
       "tracking_numbers": [
         "456"
       ],
       "tracking_url": "https://braze.com",
       "tracking_urls": [
         "https://braze.com"
       ],
       "line_items": [
         {
           "fulfillment_status": "fulfilled",
           "name": "Dark Denim Top",
           "price": "60.00",
           "product_id": 6143032066239,
           "quantity": 1,
           "requires_shipping": true,
           "sku": null,
           "title": "Dark Denim Top",
           "variant_id": 40094740549876,
           "variant_title": "Small Dark Denim Top",
           "vendor": "partners-demo"
         }
       ]
     }
   ]
 },
 "braze_id": "123abc123abc"
}
{
 "name": "shopify_partially_fulfilled_order",
 "time": "2022-05-23T14:43:34-04:00",
 "properties": {
   "order_id": 4444668657855,
   "line_items": [
     {
       "quantity": 1,
       "product_id": 6143032066239,
       "sku": null,
       "title": "Dark Denim Top",
       "variant_id": 40094740549876,
       "variant_title": "",
       "vendor": "partners-demo",
       "name": "Dark Denim Top",
       "properties": [],
       "price": "60.00",
       "fulfillment_status": "fulfilled"
     }
   ],
   "shipping": [
     {
       "title": "Standard",
       "price": "0.00"
     }
   ],
   "total_price": "130.66",
   "confirmed": true,
   "total_discounts": "0.00",
   "discount_codes": [],
   "order_number": 1093,
   "order_status_url": "https://test-store.myshopify.com/",
   "cancelled_at": null,
   "tags": "",
   "closed_at": null,
   "fulfillment_status": "partial",
   "fulfillments": [
     {
       "shipment_status": null,
       "status": "success",
       "tracking_company": "Other",
       "tracking_number": "123",
       "tracking_numbers": [
         "123"
       ],
       "tracking_url": "https://braze.com",
       "tracking_urls": [
         "https://braze.com"
       ],
       "line_items": [
         {
           "fulfillment_status": "fulfilled",
           "name": "Dark Denim Top",
           "price": "60.00",
           "product_id": 6143032066239,
           "properties": [],
           "quantity": 1,
           "requires_shipping": true,
           "sku": null,
           "title": "Dark Denim Top",
           "variant_id": 40094740549876,
           "variant_title": "",
           "vendor": "partners-demo"
         }
       ]
     }
   ]
 },
 "braze_id": "abc123abc123"
}
{
 "name": "shopify_paid_order",
 "time": "2022-05-23T13:52:38-04:00",
 "properties": {
   "order_id": 4444596371647,
   "line_items": [
     {
       "quantity": 1,
       "product_id": 6143033344191,
       "sku": null,
       "title": "LED High Tops",
       "variant_id": 40094740549876,
       "variant_title": null,
       "vendor": "partners-demo",
       "name": "LED High Tops",
       "properties": [],
       "price": "80.00",
       "fulfillment_status": null
     }
   ]
 }
}
{
    "name": "ecommerce.order_cancelled",
    "time": "2022-05-23T13:52:38-04:00",
    "properties": {
        "order_id": "820982911946154508",
        "cancel_reason": "no longer necessary",
        "total_value": 421.88,
        "subtotal_value": 396.88,
        "tax": 15.00,
        "shipping": 10.00,
        "currency": "USD",
        "total_discounts": 5,
        "discounts": [],
        "products": [
            {
                "product_id": "632910392",
                "product_name": "IPod Nano - 8GB",
                "variant_id": "808950810",
                "quantity": 1,
                "price": 199,
                "metadata": {
                    "sku": "IPOD2008PINK"
                }
            }
        ],
        "source": "braze-mock-storefront.myshopify.com",
        "metadata": {
            "order_status_url": "https://apple.myshopify.com/690933842/orders/123456abcd/authenticate?key=abcdefg",
            "order_number": "1234",
            "tags": [
                "heavy",
                "heavy2"
            ]
        }
    }
}
{
    "name": "ecommerce.order_refunded",
    "time": "2022-05-23T13:52:38-04:00",
    "properties": {
        "order_id": "820982911946154508",
        "total_value": 421.88,
        "currency": "USD",
        "products": [
            {
                "product_id": "632910392",
                "product_name": "IPod Nano - 8GB",
                "variant_id": "808950810",
                "quantity": 1,
                "price": 199,
                "metadata": {
                    "sku": "IPOD2008PINK"
                }
            }
        ],
        "source": "braze-mock-storefront.myshopify.com",
        "metadata": {
		"order_note": "item was broken"
        }
    }
}
{
	"name": "shopify_account_login",
	"properties": {
	"source": "braze-mock-storefront.myshopify.com"
  }
}

イベント: ecommerce.product_viewed
タイプ: 推奨イベント
トリガー: 顧客が商品ページを閲覧したとき
データソース: Braze SDK
ユースケース: 閲覧放棄

変数 Liquid テンプレート
product_id {{event_properties.${product_id}}}
product_name {{event_properties.${product_name}}}
variant_id {{event_properties.${variant_id}}}
image_url {{event_properties.${image_url}}}
product_url <your-store.myshopify.com>{{event_properties.${product_url}}}

URLの前にShopifyサイトのドメインを追加してください。
price {{event_properties.${price}}}
currency {{event_properties.${currency}}}
source {{event_properties.${source}}}
sku {{event_properties.${metadata}[0].sku}}
type event_properties.${type}

イベント: ecommerce.cart_updated
タイプ: 推奨イベント
トリガー: 顧客がショッピングカートに商品を追加、削除、または更新したとき
データソース: Braze SDK
ユースケース: カート放棄

カート放棄キャンバスでは、まず最初のショッピングカートLiquidタグを追加して、メッセージ内でショッピングカートのコンテキストを取得する必要があります。

{% shopping_cart {{context.${cart_id}}} %}

その後、以下のショッピングカートLiquidタグをメッセージに追加できます。

変数 Liquid テンプレート
cart_id {{ shopping_cart.cart_id }}
currency {{ shopping_cart.currency }}
total_value {{ shopping_cart.total_value }}
product_id {{ shopping_cart.products[0].product_id }}
product_name {{ shopping_cart.products[0].product_name }}
variant_id {{ shopping_cart.products[0].variant_id }}
image_url {{ shopping_cart.products[0].image_url }}
product_url {{ shopping_cart.products[0].product_url }}
quantity {{ shopping_cart.products[0].quantity }}
price {{ shopping_cart.products[0].price }}
sku {{ shopping_cart.products[0].metadata[0].sku }}
source {{ shopping_cart.source }}
metadata (value) {{ shopping_cart.metadata[0].<add_value_here> }}

イベント: ecommerce.checkout_started
タイプ: 推奨イベント
トリガー: ユーザーがチェックアウトページに移動したとき
データソース: Braze REST API
ユースケース: チェックアウト放棄

チェックアウト放棄キャンバスでは、まず次のLiquidタグを使用する必要があります。

{% shopping_cart {{context.${cart_id}}} :abort_if_not_abandoned false %}
{{context.${cart_id}}}

その後、以下のLiquidタグをメッセージに追加して、チェックアウト時点でカート内にある商品を参照できます。

変数 Liquid テンプレート
cart_id {{ shopping_cart.cart_id }}
currency {{ shopping_cart.currency }}
total_value {{ shopping_cart.total_value }}
product_id {{ shopping_cart.products[0].product_id }}
product_name {{ shopping_cart.products[0].product_name }}
variant_id {{ shopping_cart.products[0].variant_id }}
image_url {{ shopping_cart.products[0].image_url }}
product_url {{ shopping_cart.products[0].product_url }}
quantity {{ shopping_cart.products[0].quantity }}
price {{ shopping_cart.products[0].price }}
sku {{ shopping_cart.products[0].metadata.sku }}
source {{ shopping_cart.source }}
checkout_url {{ shopping_cart.metadata[0].checkout_url }}

イベント: ecommerce.order_placed
タイプ: 推奨イベント
トリガー: ユーザーがチェックアウトプロセスを正常に完了し、注文を確定したとき
データソース: Braze REST API
ユースケース: 注文確認、購入後のリターゲティング、アップセルまたはクロスセル

変数 Liquid テンプレート
cart_id {{event_properties.${cart_id}}}
currency {{event_properties.${currency}}}
discounts {{event_properties.${discounts}}}
order_id {{event_properties.${order_id}}}
product_id {{event_properties.${products}[0].product_id}}
product_name {{event_properties.${products}[0].product_name}}
variant_id {{event_properties.${products}[0].variant_id}}
quantity {{event_properties.${products}[0].quantity}}
sku {{event_properties.${products}[0].metadata.sku}}
total_discounts {{event_properties.${total_discounts}}}
order_status_url {{event_properties.${metadata}.order_status_url}}
order_number {{event_properties.${metadata}.order_number}}
tags {{event_properties.${metadata}.tags}}
referring_site {{event_properties.${metadata}.referring_site}}
payment_gateway_names {{event_properties.${metadata}.payment_gateway_names}}

イベント: shopify_fulfilled_order
タイプ: カスタムイベント
トリガー: ユーザーの注文が処理され、発送準備が整ったとき
データソース: Braze REST API
ユースケース: (トランザクション) フルフィルメントの最新情報

変数 Liquid テンプレート
注文ID {{event_properties.${order_id}}}
合計金額 {{event_properties.${total_price}}}
合計割引額 {{event_properties.${total_discounts}}}
確定ステータス {{event_properties.${confirmed}}}
注文ステータスURL {{event_properties.${order_status_url}}}
注文番号 {{event_properties.${order_number}}}
キャンセルのタイムスタンプ {{event_properties.${cancelled_at}}}
完了のタイムスタンプ {{event_properties.${closed_at}}}
商品ID {{event_properties.${line_items}[0].product_id}}
商品の数量 {{event_properties.${line_items}[0].quantity}}
商品のSKU {{event_properties.${line_items}[0].sku}}
商品のタイトル {{event_properties.${line_items}[0].title}}
商品のベンダー {{event_properties.${line_items}[0].vendor}}
商品名 {{event_properties.${line_items}[0].name}}
商品のプロパティ {{event_properties.${line_items}[0].properties}}
商品の価格 {{event_properties.${line_items}[0].price}}
配送のタイトル {{event_properties.${shipping}[0].title}}
配送料金 {{event_properties.${shipping}[0].price}}
フルフィルメントステータス {{event_properties.${fulfillment_status}}}
フルフィルメントの発送ステータス {{event_properties.${fulfillments}[0].shipment_status}}
ステータス {{event_properties.${fulfillments}[0].status}}
フルフィルメントの配送業者 {{event_properties.${fulfillments}[0].Fulfillment tracking_company}}
フルフィルメントの追跡番号 {{event_properties.${fulfillments}[0].Fulfillment tracking_number}}
フルフィルメントの追跡番号 (複数) {{event_properties.${fulfillments}[0].Fulfillment tracking_numbers}}
フルフィルメントの追跡URL {{event_properties.${fulfillments}[0].Fulfillment tracking_url}}
フルフィルメントの追跡URL (複数) {{event_properties.${fulfillments}[0].Fulfillment tracking_urls}}
フルフィルメントステータス {{event_properties.${fulfillments}[0].line_items[0].fulfillment_status}}
フルフィルメントの名前 {{event_properties.${fulfillments}[0].line_items[0].name}}
フルフィルメントの価格 {{event_properties.${fulfillments}[0].line_items[0].price}}
フルフィルメントの商品ID {{event_properties.${fulfillments}[0].line_items[0].product_id}}
フルフィルメントの数量 {{event_properties.${fulfillments}[0].line_items[0].quantity}}
フルフィルメントの配送要否 {{event_properties.${fulfillments}[0].line_items[0].requires_shipping}}
フルフィルメントのSKU {{event_properties.${fulfillments}[0].line_items[0].sku}}
フルフィルメントのタイトル {{event_properties.${fulfillments}[0].line_items[0].title}}
フルフィルメントのベンダー {{event_properties.${fulfillments}[0].line_items[0].vendor}}
バリアントID {{event_properties.${line_items}[0].variant_id}}
バリアントのタイトル {{event_properties.${line_items}[0].variant_title}}

イベント: shopify_partially_fulfilled_order
タイプ: カスタムイベント
トリガー: ユーザーの注文の一部が処理され、発送準備が整ったとき
データソース: Braze REST API
ユースケース: (トランザクション) フルフィルメントの最新情報

変数 Liquid テンプレート
注文ID {{event_properties.${order_id}}}
合計金額 {{event_properties.${total_price}}}
合計割引額 {{event_properties.${total_discounts}}}
確定ステータス {{event_properties.${confirmed}}}
注文ステータスURL {{event_properties.${order_status_url}}}
注文番号 {{event_properties.${order_number}}}
キャンセルのタイムスタンプ {{event_properties.${cancelled_at}}}
完了のタイムスタンプ {{event_properties.${closed_at}}}
商品ID {{event_properties.${line_items}[0].product_id}}
商品の数量 {{event_properties.${line_items}[0].quantity}}
商品のSKU {{event_properties.${line_items}[0].sku}}
商品のタイトル {{event_properties.${line_items}[0].title}}
商品のベンダー {{event_properties.${line_items}[0].vendor}}
商品名 {{event_properties.${line_items}[0].name}}
商品のプロパティ {{event_properties.${line_items}[0].properties}}
商品の価格 {{event_properties.${line_items}[0].price}}
配送のタイトル {{event_properties.${shipping}[0].title}}
配送料金 {{event_properties.${shipping}[0].price}}
フルフィルメントステータス {{event_properties.${fulfillment_status}}}
フルフィルメントの発送ステータス {{event_properties.${fulfillments}[0].shipment_status}}
フルフィルメントステータス {{event_properties.${fulfillments}[0].status}}
フルフィルメントの配送業者 {{event_properties.${fulfillments}[0].tracking_company}}
フルフィルメントの追跡番号 {{event_properties.${fulfillments}[0].tracking_number}}
フルフィルメントの追跡番号 (複数) {{event_properties.${fulfillments}[0].tracking_numbers}}
フルフィルメントの追跡URL {{event_properties.${fulfillments}[0].tracking_url}}
フルフィルメントの追跡URL (複数) {{event_properties.${fulfillments}[0].tracking_urls}}
フルフィルメントステータス {{event_properties.${fulfillments}[0].line_items[0].fulfillment_status}}
フルフィルメントの名前 {{event_properties.${fulfillments}[0].line_items[0].name}}
フルフィルメントの価格 {{event_properties.${fulfillments}[0].line_items[0].price}}
フルフィルメントの商品ID {{event_properties.${fulfillments}[0].line_items[0].product_id}}
フルフィルメントの数量 {{event_properties.${fulfillments}[0].line_items[0].quantity}}
フルフィルメントの配送要否 {{event_properties.${fulfillments}[0].line_items[0].requires_shipping}}
フルフィルメントのSKU {{event_properties.${fulfillments}[0].line_items[0].sku}}
フルフィルメントのタイトル {{event_properties.${fulfillments}[0].line_items[0].title}}
フルフィルメントのベンダー {{event_properties.${fulfillments}[0].line_items[0].vendor}}
バリアントID {{event_properties.${line_items}[0].variant_id}}
バリアントのタイトル {{event_properties.${line_items}[0].variant_title}}

イベント: shopify_paid_order
タイプ: カスタムイベント
トリガー: ユーザーの注文がShopify内で支払い済みとしてマークされたとき
データソース: Braze REST API
ユースケース: (トランザクション) 支払い確認

変数 Liquid テンプレート
注文ID {{event_properties.${order_id}}}
確定ステータス {{event_properties.${confirmed}}}
注文ステータスURL {{event_properties.${order_status_url}}}
注文番号 {{event_properties.${order_number}}}
キャンセルのタイムスタンプ {{event_properties.${cancelled_at}}}
合計割引額 {{event_properties.${total_discounts}}}
合計金額 {{event_properties.${total_price}}}
タグ {{event_properties.${tags}}}
割引コード {{event_properties.${discount_codes}}}
商品ID {{event_properties.${line_items}[0].product_id}}
商品の数量 {{event_properties.${line_items}[0].quantity}}
商品のSKU {{event_properties.${line_items}[0].sku}}
商品のタイトル {{event_properties.${line_items}[0].title}}
商品のベンダー {{event_properties.${line_items}[0].vendor}}
商品のプロパティ {{event_properties.${line_items}[0].properties}}
商品の価格 {{event_properties.${line_items}[0].price}}
配送のタイトル {{event_properties.${shipping}[0].title}}
配送料金 {{event_properties.${shipping}[0].price}}
バリアントID {{event_properties.${line_items}[0].variant_id}}
バリアントのタイトル {{event_properties.${line_items}[0].variant_title}}

イベント: ecommerce.order_cancelled
タイプ: 推奨イベント
トリガー: ユーザーの注文がキャンセルされたとき
データソース: Braze REST API
ユースケース: (トランザクション) 注文キャンセルの確認

変数 Liquid テンプレート
注文ID {{event_properties.${order_id}}}
合計金額 {{event_properties.${total_price}}}
合計割引額 {{event_properties.${total_discounts}}}
確定 {{event_properties.${confirmed}}}
注文ステータスURL {{event_properties.${order_status_url}}}
注文番号 {{event_properties.${order_number}}}
キャンセルのタイムスタンプ {{event_properties.${cancelled_at}}}
タグ {{event_properties.${tags}}}
割引コード {{event_properties.${discount_codes}}}
フルフィルメントステータス {{event_properties.${fulfillment_status}}}
フルフィルメント {{event_properties.${fulfillments}}}
商品ID {{event_properties.${line_items}[0].product_id}}
商品の数量 {{event_properties.${line_items}[0].quantity}}
商品のSKU {{event_properties.${line_items}[0].sku}}
商品のタイトル {{event_properties.${line_items}[0].title}}
商品のベンダー {{event_properties.${line_items}[0].vendor}}
商品名 {{event_properties.${line_items}[0].name}}
商品のプロパティ {{event_properties.${line_items}[0].properties}}
フルフィルメントステータス {{event_properties.${line_items}[0].fulfillment_status}}
配送のタイトル {{event_properties.${shipping}[0].title}}
配送料金 {{event_properties.${shipping}[0].price}}
バリアントID {{event_properties.${line_items}[0].variant_id}}
バリアントのタイトル {{event_properties.${line_items}[0].variant_title}}

イベント: ecommerce.order_refunded
タイプ: 推奨イベント
トリガー: ユーザーの注文が返金されたとき
データソース: Braze REST API
ユースケース: (トランザクション) 返金確認

変数 Liquid テンプレート
注文ID {{event_properties.${order_id}}}
注文メモ {event_properties.${note}}}
商品ID {{event_properties.${line_items}[0].product_id}}
商品の数量 {{event_properties.${line_items}[0].quantity}}
商品のSKU {{event_properties.${line_items}[0].sku}}
商品のタイトル {{event_properties.${line_items}[0].title}}
商品のベンダー {{event_properties.${line_items}[0].vendor}}
商品名 {{event_properties.${line_items}[0].name}}
商品のプロパティ {{event_properties.${line_items}[0].properties}}
商品の価格 {{event_properties.${line_items}[0].price}}
バリアントID {{event_properties.${line_items}[0].variant_id}}
バリアントのタイトル {{event_properties.${line_items}[0].variant_title}}

イベント: shopify_account_login
タイプ: カスタムイベント
トリガー: ユーザーが自分のアカウントにログインしたとき
データソース: Braze REST API
ユースケース: ウェルカムシリーズ

変数 Liquid テンプレート
source {{event_properties.${source}}}

サポートされているShopifyカスタム属性

{
  "attributes": [
    {
      "shopify_tags": "VIP_customer",
      "shopify_total_spent": "60.00",
      "shopify_orders_count": "3",
      "shopify_last_order_id": "1234567",
      "shopify_zipcode": "10001",
      "shopify_province": "null"
    }
  ]
}
属性名 説明 データソース
shopify_total_spent 顧客がこれまでの注文履歴全体で使用した合計金額。 Shopifyのcustomers/purchasing_summary Webhook
shopify_orders_count この顧客に関連付けられた注文の数。テスト注文とアーカイブ済みの注文はカウントされません。 Shopifyのcustomers/purchasing_summary Webhook
shopify_last_order_id 顧客の最後の注文のID。 Shopifyのcustomers/purchasing_summary Webhook
shopify_zipcode 顧客のデフォルト住所の郵便番号。 Shopifyのcustomers/createおよびcustomers/update Webhook
shopify_province 顧客のデフォルト住所の州・都道府県。 Shopifyのcustomers/createおよびcustomers/update Webhook
shopify_locale 顧客のロケール (enやfr-CAなど)。注文するまではBraze Webピクセルが収集したブラウザーの言語から設定され、その後は最新のチェックアウトのロケールから更新されます。 Braze Webピクセル、Shopifyのorders/* Webhook、過去の顧客データのバックフィル

Liquidパーソナライゼーション

ShopifyカスタムAttributesにLiquidパーソナライゼーションを追加するには、+ パーソナライゼーションを選択します。次に、パーソナライゼーションタイプとしてカスタム属性を選択します。

「属性」ドロップダウンが展開された「パーソナライゼーションを追加」セクション。

カスタム属性を選択したら、デフォルト値を入力し、Liquidスニペットをコピーしてメッセージに貼り付けます。

メッセージにLiquidスニペットを貼り付けている様子。

サポートされているShopify標準属性項目

  • メール
  • 名
  • 姓
  • 電話番号
  • 市区町村
  • 国

SDK データ収集

Braze SDKで収集されるデータの詳細については、SDKデータ収集を参照してください。

履歴バックフィル

Braze を接続する前の Shopify の履歴データがインポートされます。設定時に、注文イベントと顧客プロファイルをどこまでさかのぼってインポートするかを選択します。各期間は、統合を完了した日から起算されます。

Shopify 標準統合の設定または Shopify カスタム統合の設定で履歴バックフィルをオンにすると、過去の顧客と注文をセグメント、キャンペーン、キャンバスに含めることができます。オンにする場合は、以下を選択します。

  • 注文の期間: 過去90日間、過去1年間、または過去2年間 (デフォルトは過去90日間)
  • 顧客プロファイルの期間: 過去1年間、過去2年間、または全期間 (デフォルトは全期間)

設定を完了する前に、Braze は各オプションの推定レコード数と処理時間を表示します。バックフィルが完了すると、選択した期間が Shopify パートナーページに具体的な日付で表示されます。これらの選択は、設定完了後に変更できません。

Braze が Shopify の顧客をインポートする際には、設定で選択した external_id タイプが割り当てられます。

カスタムexternal IDを使用して統合する予定の場合(標準統合またはカスタム統合のいずれか)、カスタムexternal IDをShopify顧客メタフィールドとして既存のすべてのShopify顧客プロファイルに追加し、その後に履歴バックフィルを実行する必要があります。

Braze が履歴データを選択する方法

初回ロードの実行時、Braze は以下の Shopify の日付フィールドを使用します。

データ 選択可能な期間 Shopify の日付フィールド
注文イベント (注文の発生、注文の返金、注文のキャンセル) 過去90日間、過去1年間、または過去2年間 注文の作成日
ユーザープロファイル 過去1年間、過去2年間、または全期間 顧客の更新日

過去の注文を元の作成日を保持したまま Shopify に移行した場合、Braze は選択した注文期間内に作成日が含まれる注文のみをインポートします。

Shopify 履歴バックフィルの設定

  1. Shopify データを追跡ステップで 履歴バックフィルをオンにするを選択します。
  2. 注文の期間と顧客プロファイルの期間を選択します。選択内容に応じた推定件数と処理時間を確認します。
  3. 統合の設定を完了すると、Braze は初回のデータ同期を開始します。進捗状況は、統合設定の Shopify データタブで確認できます。

イベントが同期中であることを示すスピナーが表示された Shopify 統合設定ページ。

バックフィルの同期レートとタイミング

履歴バックフィルは Braze SDK ではなく Braze の Shopify 統合によって実行され、統合の設定を完了すると自動的に開始されます。

履歴バックフィルを有効にすると、Braze は Shopify から注文イベントと顧客プロファイルをバッチでインポートします。注文イベントと顧客プロファイルはそれぞれ別のタイムラインで同期されるため、一方が先に完了する場合があります。大規模なバックフィルは、同時に実行できるよう並列の期間に分割されます。

同期にかかる時間は、ストア内の履歴データの量と選択した期間によって異なります。注文数が多いストアや顧客基盤が大きいストアでは、バックフィルの完了に時間がかかる場合があります。バックフィルの速度を変更したり、より高速な同期をリクエストしたりすることはできません。

同期されるデータ

初回のデータ同期では、Braze は Braze が履歴データを選択する方法で説明されている注文イベントとユーザープロファイルをインポートします。Braze が Shopify の顧客をインポートする際には、設定で選択した external_id タイプが割り当てられます。

以下の表は、初回ロードに含まれるデータをまとめたものです。

Braze の推奨イベント Shopify カスタムイベント Braze 標準属性項目 Braze 購読ステータス
  • 注文の発生
  • 注文のキャンセル
  • 注文の返金
  • shopify_tags
  • shopify_total_spent
  • shopify_orders_count
  • shopify_last_order_id
  • shopify_zipcode
  • shopify_province
  • shopify_locale
  • メール
  • 名
  • 姓
  • 電話番号
  • 市区町村
  • 国
  • 総収益
  • 返金総額
  • 注文総数
  • この Shopify ストアに関連付けられたメールマーケティングの購読
  • この Shopify ストアに関連付けられた SMS マーケティングの購読
New Stuff!