diff --git a/shopify/assets/dashboards/shopify_customer_overview.json b/shopify/assets/dashboards/shopify_customer_overview.json index 0ac696dbf349e..e3bb4960c1ec7 100644 --- a/shopify/assets/dashboards/shopify_customer_overview.json +++ b/shopify/assets/dashboards/shopify_customer_overview.json @@ -1,6 +1,6 @@ { "title": "Shopify - Customer Overview", - "description": "", + "description": "The Shopify Customer Overview Dashboard provides an overview of customers within your store. It provides insights into customer's marketing and order details.", "widgets": [ { "id": 6457589008412640, @@ -95,51 +95,6 @@ "height": 3 } }, - { - "id": 2522113371979004, - "definition": { - "title": "First Time Customers", - "title_size": "16", - "title_align": "left", - "type": "query_value", - "requests": [ - { - "formulas": [ - { - "formula": "query1" - } - ], - "queries": [ - { - "data_source": "logs", - "name": "query1", - "indexes": [ - "*" - ], - "compute": { - "aggregation": "cardinality", - "metric": "@usr.id" - }, - "group_by": [], - "search": { - "query": "source:shopify service:customer @numberOfOrders:1 $customer_name $customer_id $currency" - }, - "storage": "hot" - } - ], - "response_format": "scalar" - } - ], - "autoscale": true, - "precision": 2 - }, - "layout": { - "x": 4, - "y": 3, - "width": 4, - "height": 3 - } - }, { "id": 3033015122548506, "definition": { @@ -179,7 +134,7 @@ "precision": 2 }, "layout": { - "x": 8, + "x": 4, "y": 3, "width": 4, "height": 3 @@ -253,19 +208,19 @@ "precision": 2 }, "layout": { - "x": 0, - "y": 6, + "x": 8, + "y": 3, "width": 4, - "height": 4 + "height": 3 } }, { - "id": 6324267437916298, + "id": 4536649778544610, "definition": { - "title": "Sales by Customer", + "title": "Top Customers by Order Count", "title_size": "16", "title_align": "left", - "type": "query_table", + "type": "toplist", "requests": [ { "queries": [ @@ -276,26 +231,26 @@ "*" ], "compute": { - "aggregation": "avg", - "metric": "@amountSpent.amount" + "aggregation": "max", + "metric": "@numberOfOrders" }, "group_by": [ { "facet": "@usr.name", - "limit": 100, + "limit": 25, "sort": { "order": "desc", - "aggregation": "avg", - "metric": "@amountSpent.amount" + "aggregation": "max", + "metric": "@numberOfOrders" } }, { - "facet": "@amountSpent.currencyCode", - "limit": 100, + "facet": "@usr.id", + "limit": 25, "sort": { "order": "desc", - "aggregation": "avg", - "metric": "@amountSpent.amount" + "aggregation": "max", + "metric": "@numberOfOrders" } } ], @@ -306,9 +261,13 @@ } ], "response_format": "scalar", - "text_formats": [], + "formulas": [ + { + "formula": "query1" + } + ], "sort": { - "count": 10000, + "count": 625, "order_by": [ { "type": "formula", @@ -316,24 +275,68 @@ "order": "desc" } ] + } + } + ], + "style": { + "display": { + "type": "stacked", + "legend": "inline" + }, + "palette": "datadog16" + } + }, + "layout": { + "x": 0, + "y": 6, + "width": 4, + "height": 4 + } + }, + { + "id": 6324267437916298, + "definition": { + "title": "Sales by Customer", + "title_size": "16", + "title_align": "left", + "requests": [ + { + "response_format": "event_list", + "query": { + "data_source": "logs_stream", + "query_string": "source:shopify service:customer $customer_name $customer_id $currency", + "indexes": [], + "storage": "hot", + "sort": { + "column": "timestamp", + "order": "desc" + } }, - "formulas": [ + "columns": [ { - "cell_display_mode": "number", - "alias": "Order Value", - "conditional_formats": [ - { - "comparator": ">=", - "value": 0, - "palette": "black_on_light_green" - } - ], - "formula": "query1" + "field": "timestamp", + "width": "auto" + }, + { + "field": "@usr.id", + "width": "auto" + }, + { + "field": "@usr.name", + "width": "auto" + }, + { + "field": "amountSpent.currencyCode", + "width": "auto" + }, + { + "field": "amountSpent.amount", + "width": "auto" } ] } ], - "has_search_bar": "auto" + "type": "list_stream" }, "layout": { "x": 4, @@ -343,9 +346,30 @@ } }, { - "id": 4312648521138476, + "id": 289959563304157, "definition": { - "title": "Amount Spent by First Time Customers (Avg)", + "type": "note", + "content": "**Note**: Panels `Average Spending of Customers by Currency` and `Average Spending of Returning Customers by Currency` display the average amount spent across all orders, including paid, refunded, and other payment status.", + "background_color": "yellow", + "font_size": "16", + "text_align": "left", + "vertical_align": "center", + "show_tick": false, + "tick_pos": "50%", + "tick_edge": "left", + "has_padding": true + }, + "layout": { + "x": 0, + "y": 10, + "width": 12, + "height": 1 + } + }, + { + "id": 6208927249201918, + "definition": { + "title": "Average Spending of Customers by Currency", "title_size": "16", "title_align": "left", "type": "toplist", @@ -374,19 +398,12 @@ } ], "search": { - "query": "source:shopify service:customer @numberOfOrders:1 $customer_name $customer_id $currency" + "query": "source:shopify service:customer $customer_name $customer_id $currency" }, "storage": "hot" } ], "response_format": "scalar", - "conditional_formats": [ - { - "comparator": ">=", - "value": 0, - "palette": "white_on_green" - } - ], "formulas": [ { "formula": "query1" @@ -413,15 +430,15 @@ }, "layout": { "x": 0, - "y": 10, - "width": 4, + "y": 11, + "width": 6, "height": 4 } }, { "id": 8540082775305124, "definition": { - "title": "Amount Spent by Returning Customers (Avg)", + "title": "Average Spending of Returning Customers by Currency", "title_size": "16", "title_align": "left", "type": "toplist", @@ -488,16 +505,16 @@ } }, "layout": { - "x": 4, - "y": 10, - "width": 4, + "x": 6, + "y": 11, + "width": 6, "height": 4 } }, { - "id": 6208927249201918, + "id": 2471531239284296, "definition": { - "title": "Amount Spent by Currency (Avg)", + "title": "Customers by City", "title_size": "16", "title_align": "left", "type": "toplist", @@ -511,22 +528,22 @@ "*" ], "compute": { - "aggregation": "avg", - "metric": "@amountSpent.amount" + "aggregation": "cardinality", + "metric": "@usr.id" }, "group_by": [ { - "facet": "@amountSpent.currencyCode", + "facet": "@defaultAddress.city", "limit": 25, "sort": { "order": "desc", - "aggregation": "avg", - "metric": "@amountSpent.amount" + "aggregation": "cardinality", + "metric": "@usr.id" } } ], "search": { - "query": "source:shopify service:customer $customer_name $customer_id $currency" + "query": "source:shopify service:customer -@defaultAddress.city:\"\" $customer_name $customer_id $currency" }, "storage": "hot" } @@ -557,19 +574,18 @@ } }, "layout": { - "x": 8, - "y": 10, - "width": 4, + "x": 0, + "y": 15, + "width": 6, "height": 4 } }, { - "id": 2471531239284296, + "id": 2373335191656186, "definition": { - "title": "Customers by City", + "title": "Customers by Subscription Status", "title_size": "16", "title_align": "left", - "type": "toplist", "requests": [ { "queries": [ @@ -585,7 +601,7 @@ }, "group_by": [ { - "facet": "@defaultAddress.city", + "facet": "@productSubscriberStatus", "limit": 25, "sort": { "order": "desc", @@ -595,19 +611,22 @@ } ], "search": { - "query": "source:shopify service:customer -@defaultAddress.city:\"\" $customer_name $customer_id $currency" + "query": "source:shopify service:customer $customer_name $customer_id $currency" }, "storage": "hot" } ], "response_format": "scalar", + "style": { + "palette": "datadog16" + }, "formulas": [ { "formula": "query1" } ], "sort": { - "count": 25, + "count": 500, "order_by": [ { "type": "formula", @@ -618,17 +637,15 @@ } } ], - "style": { - "display": { - "type": "stacked", - "legend": "automatic" - } + "type": "sunburst", + "legend": { + "type": "table" } }, "layout": { - "x": 0, - "y": 14, - "width": 4, + "x": 6, + "y": 15, + "width": 6, "height": 4 } }, @@ -696,9 +713,9 @@ } }, "layout": { - "x": 4, - "y": 14, - "width": 8, + "x": 0, + "y": 19, + "width": 12, "height": 4 } }, @@ -710,11 +727,6 @@ "title_align": "left", "requests": [ { - "formulas": [ - { - "formula": "query1" - } - ], "queries": [ { "data_source": "logs", @@ -744,6 +756,14 @@ } ], "response_format": "scalar", + "style": { + "palette": "datadog16" + }, + "formulas": [ + { + "formula": "query1" + } + ], "sort": { "count": 500, "order_by": [ @@ -753,9 +773,6 @@ "order": "desc" } ] - }, - "style": { - "palette": "datadog16" } } ], @@ -766,7 +783,7 @@ }, "layout": { "x": 0, - "y": 18, + "y": 23, "width": 6, "height": 4 } @@ -779,11 +796,6 @@ "title_align": "left", "requests": [ { - "formulas": [ - { - "formula": "query1" - } - ], "queries": [ { "data_source": "logs", @@ -813,235 +825,14 @@ } ], "response_format": "scalar", - "sort": { - "count": 500, - "order_by": [ - { - "type": "formula", - "index": 0, - "order": "desc" - } - ] - }, "style": { "palette": "datadog16" - } - } - ], - "type": "sunburst", - "legend": { - "type": "table" - } - }, - "layout": { - "x": 6, - "y": 18, - "width": 6, - "height": 4 - } - }, - { - "id": 3112514483697428, - "definition": { - "title": "Customers by Last Order Value", - "title_size": "16", - "title_align": "left", - "type": "toplist", - "requests": [ - { - "queries": [ - { - "data_source": "logs", - "name": "query1", - "indexes": [ - "*" - ], - "compute": { - "aggregation": "avg", - "metric": "@lastOrder.totalPriceSet.shopMoney.amount" - }, - "group_by": [ - { - "facet": "@usr.name", - "limit": 25, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@lastOrder.totalPriceSet.shopMoney.amount" - } - }, - { - "facet": "@lastOrder.totalPriceSet.shopMoney.currencyCode", - "limit": 25, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@lastOrder.totalPriceSet.shopMoney.amount" - } - } - ], - "search": { - "query": "source:shopify service:customer $customer_name $customer_id $currency" - }, - "storage": "hot" - } - ], - "response_format": "scalar", - "formulas": [ - { - "formula": "query1" - } - ], - "sort": { - "count": 625, - "order_by": [ - { - "type": "formula", - "index": 0, - "order": "desc" - } - ] - } - } - ], - "style": { - "display": { - "type": "stacked", - "legend": "automatic" - } - } - }, - "layout": { - "x": 0, - "y": 22, - "width": 3, - "height": 4 - } - }, - { - "id": 4536649778544610, - "definition": { - "title": "Top Customers by Order Count", - "title_size": "16", - "title_align": "left", - "time": { - "hide_incomplete_cost_data": true - }, - "type": "toplist", - "requests": [ - { - "queries": [ - { - "data_source": "logs", - "name": "query1", - "indexes": [ - "*" - ], - "compute": { - "aggregation": "max", - "metric": "@numberOfOrders" - }, - "group_by": [ - { - "facet": "@usr.name", - "limit": 25, - "sort": { - "order": "desc", - "aggregation": "max", - "metric": "@numberOfOrders" - } - }, - { - "facet": "@usr.id", - "limit": 25, - "sort": { - "order": "desc", - "aggregation": "max", - "metric": "@numberOfOrders" - } - } - ], - "search": { - "query": "source:shopify service:customer $customer_name $customer_id $currency" - }, - "storage": "hot" - } - ], - "response_format": "scalar", - "formulas": [ - { - "formula": "query1" - } - ], - "sort": { - "count": 625, - "order_by": [ - { - "type": "formula", - "index": 0, - "order": "desc" - } - ] - } - } - ], - "style": { - "display": { - "type": "stacked", - "legend": "none" - }, - "palette": "datadog16" - } - }, - "layout": { - "x": 3, - "y": 22, - "width": 3, - "height": 4 - } - }, - { - "id": 2373335191656186, - "definition": { - "title": "Customers by Subscription Status", - "title_size": "16", - "title_align": "left", - "requests": [ - { + }, "formulas": [ { "formula": "query1" } ], - "queries": [ - { - "data_source": "logs", - "name": "query1", - "indexes": [ - "*" - ], - "compute": { - "aggregation": "cardinality", - "metric": "@usr.id" - }, - "group_by": [ - { - "facet": "@productSubscriberStatus", - "limit": 25, - "sort": { - "order": "desc", - "aggregation": "cardinality", - "metric": "@usr.id" - } - } - ], - "search": { - "query": "source:shopify service:customer $customer_name $customer_id $currency" - }, - "storage": "hot" - } - ], - "response_format": "scalar", "sort": { "count": 500, "order_by": [ @@ -1051,9 +842,6 @@ "order": "desc" } ] - }, - "style": { - "palette": "datadog16" } } ], @@ -1064,7 +852,7 @@ }, "layout": { "x": 6, - "y": 22, + "y": 23, "width": 6, "height": 4 } @@ -1082,21 +870,37 @@ "data_source": "logs_stream", "query_string": "source:shopify service:customer $customer_name $customer_id $currency", "indexes": [], - "storage": "hot" + "storage": "hot", + "sort": { + "column": "timestamp", + "order": "desc" + } }, "columns": [ { - "field": "usr.id", + "field": "timestamp", + "width": "auto" + }, + { + "field": "@usr.id", "width": "auto" }, { - "field": "usr.name", + "field": "@usr.name", "width": "auto" }, { "field": "numberOfOrders", "width": "auto" }, + { + "field": "amountSpent.currencyCode", + "width": "auto" + }, + { + "field": "amountSpent.amount", + "width": "auto" + }, { "field": "lifetimeDuration", "width": "auto" @@ -1124,7 +928,7 @@ }, "layout": { "x": 0, - "y": 26, + "y": 27, "width": 12, "height": 4 } diff --git a/shopify/assets/dashboards/shopify_event_overview.json b/shopify/assets/dashboards/shopify_event_overview.json index 30b17a2994e9f..4a4ccbe907f43 100644 --- a/shopify/assets/dashboards/shopify_event_overview.json +++ b/shopify/assets/dashboards/shopify_event_overview.json @@ -1,6 +1,6 @@ { "title": "Shopify - Event Overview", - "description": "", + "description": "The Shopify Event Overview Dashboard provides an overview of event logs, offering insights into events, type, and action distribution.", "widgets": [ { "id": 2362748552655712, diff --git a/shopify/assets/dashboards/shopify_order_overview.json b/shopify/assets/dashboards/shopify_order_overview.json index 7173613cf3067..f71df5641de67 100644 --- a/shopify/assets/dashboards/shopify_order_overview.json +++ b/shopify/assets/dashboards/shopify_order_overview.json @@ -1,6 +1,6 @@ { "title": "Shopify - Order Overview", - "description": "", + "description": "The Shopify Orders Overview Dashboard provides an overview of orders within your store. It provides insights into order tracking, fulfillments, customers, and product details.", "widgets": [ { "id": 3630919149544800, @@ -91,7 +91,7 @@ }, "group_by": [], "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -143,7 +143,7 @@ }, "group_by": [], "search": { - "query": "source:shopify service:order @confirmed:true $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order @confirmed:true $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -188,7 +188,7 @@ }, "group_by": [], "search": { - "query": "source:shopify service:order @refunds.transactions.status:success $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order @refunds.transactions.status:success $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -233,7 +233,7 @@ }, "group_by": [], "search": { - "query": "source:shopify service:order @buyer_accepts_marketing:true $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order @buyer_accepts_marketing:true $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -278,7 +278,7 @@ }, "group_by": [], "search": { - "query": "source:shopify service:order @closed_at:* $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order @closed_at:* $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -323,7 +323,7 @@ }, "group_by": [], "search": { - "query": "source:shopify service:order @cancelled_at:* $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order @cancelled_at:* $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -368,7 +368,7 @@ }, "group_by": [], "search": { - "query": "source:shopify service:order (@tax_exempt:true OR @tax_included:false) $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order (@tax_exempt:true OR @tax_included:false) $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -417,7 +417,7 @@ }, "group_by": [], "search": { - "query": "source:shopify service:order @line_items.gift_card:true $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order @line_items.gift_card:true $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -436,308 +436,150 @@ } }, { - "id": 4902698799419696, + "id": 4183443318605663, "definition": { - "title": "Average Order Price by Customer", + "title": "Order Summary", "title_size": "16", "title_align": "left", - "type": "toplist", "requests": [ { - "queries": [ - { - "data_source": "logs", - "name": "query1", - "indexes": [ - "*" - ], - "compute": { - "aggregation": "avg", - "metric": "@total_price" - }, - "group_by": [ - { - "facet": "@usr.name", - "limit": 25, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@total_price" - } - }, - { - "facet": "@currency", - "limit": 25, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@total_price" - } - } - ], - "search": { - "query": "source:shopify service:order -@usr.name:\" \" $order_id $customer_name $customer_city $currency" - }, - "storage": "hot" + "response_format": "event_list", + "query": { + "data_source": "logs_stream", + "query_string": "source:shopify service:order $order_number $customer_name $customer_city $currency", + "indexes": [], + "storage": "hot", + "sort": { + "column": "timestamp", + "order": "desc" } - ], - "response_format": "scalar", - "formulas": [ + }, + "columns": [ { - "formula": "query1" + "field": "timestamp", + "width": "auto" + }, + { + "field": "order_number", + "width": "auto" + }, + { + "field": "financial_status", + "width": "auto" + }, + { + "field": "currency", + "width": "auto" + }, + { + "field": "total_price", + "width": "auto" + }, + { + "field": "subtotal_price", + "width": "auto" + }, + { + "field": "total_tax", + "width": "auto" + }, + { + "field": "total_discounts", + "width": "auto" + }, + { + "field": "total_tip_received", + "width": "auto" } - ], - "sort": { - "count": 625, - "order_by": [ - { - "type": "formula", - "index": 0, - "order": "desc" - } - ] - } + ] } ], - "style": { - "display": { - "type": "stacked", - "legend": "automatic" - } - } + "type": "list_stream" }, "layout": { "x": 0, "y": 8, - "width": 3, + "width": 12, "height": 4 } }, { - "id": 3843387744924516, + "id": 6076451033442339, "definition": { - "title": "Order Summary (rounded price)", + "type": "note", + "content": " **Note**: The panel `Average Order Price by Customer` displays the average order price for each customer, including paid, refunded, and other payment statuses.\n", + "background_color": "yellow", + "font_size": "16", + "text_align": "center", + "vertical_align": "center", + "show_tick": true, + "tick_pos": "50%", + "tick_edge": "right", + "has_padding": true + }, + "layout": { + "x": 0, + "y": 12, + "width": 2, + "height": 4 + } + }, + { + "id": 4902698799419696, + "definition": { + "title": "Average Order Price by Customer", "title_size": "16", "title_align": "left", - "type": "query_table", + "type": "toplist", "requests": [ { "queries": [ { - "data_source": "logs", "name": "query1", - "indexes": [ - "*" - ], - "compute": { - "aggregation": "avg", - "metric": "@total_price" - }, - "group_by": [ - { - "facet": "@id", - "limit": 100, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@total_price" - } - }, - { - "facet": "@currency", - "limit": 100, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@total_price" - } - } - ], - "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" - }, - "storage": "hot" - }, - { "data_source": "logs", - "name": "query2", - "indexes": [ - "*" - ], - "compute": { - "aggregation": "avg", - "metric": "@subtotal_price" - }, - "group_by": [ - { - "facet": "@id", - "limit": 100, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@total_price" - } - }, - { - "facet": "@currency", - "limit": 100, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@total_price" - } - } - ], "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order -@usr.name:\" \" @usr.name:* $order_number $customer_name $customer_city $currency" }, - "storage": "hot" - }, - { - "data_source": "logs", - "name": "query3", "indexes": [ "*" ], - "compute": { - "aggregation": "avg", - "metric": "@total_discounts" - }, "group_by": [ { - "facet": "@id", - "limit": 100, + "facet": "@usr.name", + "limit": 25, "sort": { - "order": "desc", "aggregation": "avg", - "metric": "@total_price" - } - }, - { - "facet": "@currency", - "limit": 100, - "sort": { "order": "desc", - "aggregation": "avg", "metric": "@total_price" - } - } - ], - "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" - }, - "storage": "hot" - }, - { - "data_source": "logs", - "name": "query4", - "indexes": [ - "*" - ], - "compute": { - "aggregation": "avg", - "metric": "@total_line_items_price" - }, - "group_by": [ - { - "facet": "@id", - "limit": 100, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@total_price" - } + }, + "should_exclude_missing": true }, { "facet": "@currency", - "limit": 100, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@total_price" - } - } - ], - "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" - }, - "storage": "hot" - }, - { - "data_source": "logs", - "name": "query5", - "indexes": [ - "*" - ], - "compute": { - "aggregation": "avg", - "metric": "@total_tax" - }, - "group_by": [ - { - "facet": "@id", - "limit": 100, + "limit": 25, "sort": { - "order": "desc", "aggregation": "avg", - "metric": "@total_price" - } - }, - { - "facet": "@currency", - "limit": 100, - "sort": { "order": "desc", - "aggregation": "avg", "metric": "@total_price" - } + }, + "should_exclude_missing": true } ], - "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" - }, - "storage": "hot" - }, - { - "data_source": "logs", - "name": "query6", - "indexes": [ - "*" - ], "compute": { "aggregation": "avg", - "metric": "@total_tip_received" - }, - "group_by": [ - { - "facet": "@id", - "limit": 100, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@total_price" - } - }, - { - "facet": "@currency", - "limit": 100, - "sort": { - "order": "desc", - "aggregation": "avg", - "metric": "@total_price" - } - } - ], - "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "metric": "@total_price" }, "storage": "hot" } ], "response_format": "scalar", - "text_formats": [], + "formulas": [ + { + "formula": "query1" + } + ], "sort": { - "count": 60000, + "count": 625, "order_by": [ { "type": "formula", @@ -745,54 +587,27 @@ "order": "desc" } ] - }, - "formulas": [ - { - "cell_display_mode": "bar", - "alias": "Total Price", - "formula": "query1" - }, - { - "cell_display_mode": "bar", - "alias": "Sub Total Price", - "formula": "query2" - }, - { - "cell_display_mode": "bar", - "alias": "Total Discount", - "formula": "query3" - }, - { - "cell_display_mode": "bar", - "alias": "Total Line Item Price", - "formula": "query4" - }, - { - "cell_display_mode": "bar", - "alias": "Total Tax", - "formula": "query5" - }, - { - "cell_display_mode": "bar", - "alias": "Total Tip Received", - "formula": "query6" - } - ] + } } ], - "has_search_bar": "auto" + "style": { + "display": { + "type": "stacked", + "legend": "automatic" + } + } }, "layout": { - "x": 3, - "y": 8, - "width": 9, + "x": 2, + "y": 12, + "width": 5, "height": 4 } }, { - "id": 7339194611439248, + "id": 445727493366610, "definition": { - "title": "Top Ordered Products", + "title": "Top Customers by Order", "title_size": "16", "title_align": "left", "type": "toplist", @@ -811,7 +626,7 @@ }, "group_by": [ { - "facet": "@line_items.title", + "facet": "@usr.name", "limit": 25, "sort": { "order": "desc", @@ -821,7 +636,7 @@ } ], "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order -@usr.name:\" \" $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -852,16 +667,16 @@ } }, "layout": { - "x": 0, + "x": 7, "y": 12, - "width": 4, + "width": 5, "height": 4 } }, { - "id": 445727493366610, + "id": 7339194611439248, "definition": { - "title": "Top Customers by Order", + "title": "Top Ordered Products", "title_size": "16", "title_align": "left", "type": "toplist", @@ -880,7 +695,7 @@ }, "group_by": [ { - "facet": "@usr.name", + "facet": "@line_items.title", "limit": 25, "sort": { "order": "desc", @@ -890,7 +705,7 @@ } ], "search": { - "query": "source:shopify service:order -@usr.name:\" \" $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -921,9 +736,9 @@ } }, "layout": { - "x": 4, - "y": 12, - "width": 4, + "x": 0, + "y": 16, + "width": 6, "height": 4 } }, @@ -959,7 +774,7 @@ } ], "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -990,9 +805,9 @@ } }, "layout": { - "x": 8, - "y": 12, - "width": 4, + "x": 6, + "y": 16, + "width": 6, "height": 4 } }, @@ -1004,11 +819,6 @@ "title_align": "left", "requests": [ { - "formulas": [ - { - "formula": "query1" - } - ], "queries": [ { "data_source": "logs", @@ -1032,12 +842,20 @@ } ], "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order $order_number $customer_name $customer_city $currency" }, "storage": "hot" } ], "response_format": "scalar", + "style": { + "palette": "datadog16" + }, + "formulas": [ + { + "formula": "query1" + } + ], "sort": { "count": 500, "order_by": [ @@ -1047,9 +865,6 @@ "order": "desc" } ] - }, - "style": { - "palette": "datadog16" } } ], @@ -1060,7 +875,7 @@ }, "layout": { "x": 0, - "y": 16, + "y": 20, "width": 6, "height": 4 } @@ -1073,11 +888,6 @@ "title_align": "left", "requests": [ { - "formulas": [ - { - "formula": "query1" - } - ], "queries": [ { "data_source": "logs", @@ -1101,12 +911,20 @@ } ], "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order $order_number $customer_name $customer_city $currency" }, "storage": "hot" } ], "response_format": "scalar", + "style": { + "palette": "datadog16" + }, + "formulas": [ + { + "formula": "query1" + } + ], "sort": { "count": 500, "order_by": [ @@ -1116,9 +934,6 @@ "order": "desc" } ] - }, - "style": { - "palette": "datadog16" } } ], @@ -1129,7 +944,7 @@ }, "layout": { "x": 6, - "y": 16, + "y": 20, "width": 6, "height": 4 } @@ -1166,7 +981,7 @@ } ], "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -1198,7 +1013,7 @@ }, "layout": { "x": 0, - "y": 20, + "y": 24, "width": 6, "height": 4 } @@ -1236,7 +1051,7 @@ } ], "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -1268,7 +1083,7 @@ }, "layout": { "x": 6, - "y": 20, + "y": 24, "width": 6, "height": 4 } @@ -1282,11 +1097,6 @@ "requests": [ { "response_format": "scalar", - "formulas": [ - { - "formula": "query1" - } - ], "queries": [ { "data_source": "logs", @@ -1310,7 +1120,7 @@ } ], "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -1318,6 +1128,11 @@ "style": { "palette": "datadog16" }, + "formulas": [ + { + "formula": "query1" + } + ], "sort": { "count": 10, "order_by": [ @@ -1337,7 +1152,7 @@ }, "layout": { "x": 0, - "y": 24, + "y": 28, "width": 6, "height": 4 } @@ -1374,7 +1189,7 @@ } ], "search": { - "query": "source:shopify service:order $order_id $customer_name $customer_city $currency" + "query": "source:shopify service:order $order_number $customer_name $customer_city $currency" }, "storage": "hot" } @@ -1407,7 +1222,7 @@ }, "layout": { "x": 6, - "y": 24, + "y": 28, "width": 6, "height": 4 } @@ -1423,21 +1238,21 @@ "response_format": "event_list", "query": { "data_source": "logs_stream", - "query_string": "source:shopify service:order $order_id $customer_name $customer_city $currency", + "query_string": "source:shopify service:order $order_number $customer_name $customer_city $currency", "indexes": [], - "storage": "hot" + "storage": "hot", + "sort": { + "column": "timestamp", + "order": "desc" + } }, "columns": [ { - "field": "@id", + "field": "timestamp", "width": "auto" }, { - "field": "usr.name", - "width": "auto" - }, - { - "field": "total_price", + "field": "order_number", "width": "auto" }, { @@ -1445,7 +1260,7 @@ "width": "auto" }, { - "field": "currency", + "field": "@usr.name", "width": "auto" }, { @@ -1459,7 +1274,7 @@ }, "layout": { "x": 0, - "y": 28, + "y": 32, "width": 12, "height": 4 } @@ -1467,8 +1282,8 @@ ], "template_variables": [ { - "name": "order_id", - "prefix": "@id", + "name": "order_number", + "prefix": "@order_number", "available_values": [], "default": "*" }, diff --git a/shopify/assets/dashboards/shopify_product_overview.json b/shopify/assets/dashboards/shopify_product_overview.json index 6d10b3c2a8954..a106361b5503b 100644 --- a/shopify/assets/dashboards/shopify_product_overview.json +++ b/shopify/assets/dashboards/shopify_product_overview.json @@ -1,6 +1,6 @@ { "title": "Shopify - Product Overview", - "description": "", + "description": "The Shopify Product Overview Dashboard provides an overview of products within your store. It provides insights into product types, status distribution, inventory, and variant details.", "widgets": [ { "id": 8506652285430826, @@ -120,60 +120,6 @@ "height": 3 } }, - { - "id": 6613518820826564, - "definition": { - "title": "Top Product Count by Type", - "type": "treemap", - "requests": [ - { - "formulas": [ - { - "formula": "query1" - } - ], - "queries": [ - { - "data_source": "logs", - "name": "query1", - "indexes": [ - "*" - ], - "compute": { - "aggregation": "cardinality", - "metric": "@id" - }, - "group_by": [ - { - "facet": "@productType", - "limit": 25, - "sort": { - "order": "desc", - "aggregation": "cardinality", - "metric": "@id" - } - } - ], - "search": { - "query": "source:shopify service:product -@productType:\"\" $product_name $product_type $product_id $currency" - }, - "storage": "hot" - } - ], - "response_format": "scalar", - "style": { - "palette": "datadog16" - } - } - ] - }, - "layout": { - "x": 3, - "y": 4, - "width": 9, - "height": 3 - } - }, { "id": 4043889896241554, "definition": { @@ -213,10 +159,10 @@ "precision": 2 }, "layout": { - "x": 0, - "y": 7, - "width": 4, - "height": 2 + "x": 3, + "y": 4, + "width": 3, + "height": 3 } }, { @@ -258,10 +204,10 @@ "precision": 2 }, "layout": { - "x": 4, - "y": 7, - "width": 4, - "height": 2 + "x": 6, + "y": 4, + "width": 3, + "height": 3 } }, { @@ -303,10 +249,64 @@ "precision": 2 }, "layout": { - "x": 8, + "x": 9, + "y": 4, + "width": 3, + "height": 3 + } + }, + { + "id": 6613518820826564, + "definition": { + "title": "Top Product Count by Type", + "type": "treemap", + "requests": [ + { + "queries": [ + { + "data_source": "logs", + "name": "query1", + "indexes": [ + "*" + ], + "compute": { + "aggregation": "cardinality", + "metric": "@id" + }, + "group_by": [ + { + "facet": "@productType", + "limit": 25, + "sort": { + "order": "desc", + "aggregation": "cardinality", + "metric": "@id" + } + } + ], + "search": { + "query": "source:shopify service:product -@productType:\"\" $product_name $product_type $product_id $currency" + }, + "storage": "hot" + } + ], + "response_format": "scalar", + "style": { + "palette": "datadog16" + }, + "formulas": [ + { + "formula": "query1" + } + ] + } + ] + }, + "layout": { + "x": 0, "y": 7, - "width": 4, - "height": 2 + "width": 8, + "height": 4 } }, { @@ -318,11 +318,6 @@ "requests": [ { "response_format": "scalar", - "formulas": [ - { - "formula": "query1" - } - ], "queries": [ { "data_source": "logs", @@ -354,6 +349,11 @@ "style": { "palette": "datadog16" }, + "formulas": [ + { + "formula": "query1" + } + ], "sort": { "count": 10, "order_by": [ @@ -368,12 +368,12 @@ ], "type": "sunburst", "legend": { - "type": "inline" + "type": "table" } }, "layout": { - "x": 0, - "y": 9, + "x": 8, + "y": 7, "width": 4, "height": 4 } @@ -381,7 +381,7 @@ { "id": 3849686844214096, "definition": { - "title": "Product Variant Price (Avg)", + "title": "Product Variant Pricing Summary", "title_size": "16", "title_align": "left", "type": "query_table", @@ -483,7 +483,7 @@ "order_by": [ { "type": "formula", - "index": 2, + "index": 0, "order": "desc" } ] @@ -491,18 +491,13 @@ "formulas": [ { "cell_display_mode": "number", - "alias": "Max Variant Price", + "alias": "Average Max Variant Price", "formula": "query1" }, { "cell_display_mode": "number", - "alias": "Min Variant Price", + "alias": "Average Min Variant Price", "formula": "query2" - }, - { - "alias": "Average Variant Price", - "cell_display_mode": "bar", - "formula": "(query1 + query2) / 2" } ] } @@ -510,9 +505,30 @@ "has_search_bar": "auto" }, "layout": { - "x": 4, - "y": 9, - "width": 8, + "x": 0, + "y": 11, + "width": 10, + "height": 4 + } + }, + { + "id": 4488919335627787, + "definition": { + "type": "note", + "content": "**Note**: The panel `Product Variant Pricing Summary` displays the average min and max variant prices for the product, reflecting changes in price over time.", + "background_color": "yellow", + "font_size": "16", + "text_align": "center", + "vertical_align": "center", + "show_tick": true, + "tick_pos": "50%", + "tick_edge": "left", + "has_padding": true + }, + "layout": { + "x": 10, + "y": 11, + "width": 2, "height": 4 } }, @@ -529,9 +545,17 @@ "data_source": "logs_stream", "query_string": "source:shopify service:product $product_name $product_type $product_id $currency", "indexes": [], - "storage": "hot" + "storage": "hot", + "sort": { + "column": "timestamp", + "order": "desc" + } }, "columns": [ + { + "field": "timestamp", + "width": "auto" + }, { "field": "legacyResourceId", "width": "auto" @@ -557,15 +581,15 @@ "width": "auto" }, { - "field": "priceRangeV2.maxVariantPrice.amount", + "field": "priceRangeV2.maxVariantPrice.currencyCode", "width": "auto" }, { - "field": "priceRangeV2.minVariantPrice.amount", + "field": "priceRangeV2.maxVariantPrice.amount", "width": "auto" }, { - "field": "priceRangeV2.maxVariantPrice.currencyCode", + "field": "priceRangeV2.minVariantPrice.amount", "width": "auto" }, { @@ -583,7 +607,7 @@ }, "layout": { "x": 0, - "y": 13, + "y": 15, "width": 12, "height": 5 } diff --git a/shopify/assets/logs/shopify.yaml b/shopify/assets/logs/shopify.yaml index c099b9da32853..bb49b0ebee534 100644 --- a/shopify/assets/logs/shopify.yaml +++ b/shopify/assets/logs/shopify.yaml @@ -156,6 +156,46 @@ pipeline: targetType: attribute preserveSource: false overrideOnConflict: false + - type: attribute-remapper + name: Map `current_total_price` to `total_price` + enabled: true + sources: + - current_total_price + sourceType: attribute + target: total_price + targetType: attribute + preserveSource: false + overrideOnConflict: true + - type: attribute-remapper + name: Map `current_subtotal_price` to `subtotal_price` + enabled: true + sources: + - current_subtotal_price + sourceType: attribute + target: subtotal_price + targetType: attribute + preserveSource: false + overrideOnConflict: true + - type: attribute-remapper + name: Map `current_total_tax` to `total_tax` + enabled: true + sources: + - current_total_tax + sourceType: attribute + target: total_tax + targetType: attribute + preserveSource: false + overrideOnConflict: true + - type: attribute-remapper + name: Map `current_total_discounts` to `total_discounts` + enabled: true + sources: + - current_total_discounts + sourceType: attribute + target: total_discounts + targetType: attribute + preserveSource: false + overrideOnConflict: true - type: string-builder-processor name: Define `usr.name` equal to %{customer.first_name} %{customer.last_name} enabled: true diff --git a/shopify/assets/logs/shopify_tests.yaml b/shopify/assets/logs/shopify_tests.yaml index 3245c3565d2b7..fa8572a56e904 100644 --- a/shopify/assets/logs/shopify_tests.yaml +++ b/shopify/assets/logs/shopify_tests.yaml @@ -38,6 +38,7 @@ tests: { "confirmation_number" : "L5MIX0PUW", "fulfillment_status" : "fulfilled", + "current_subtotal_price" : "1000.00", "total_outstanding" : "1296.82", "order_number" : 1002, "created_at" : "2024-08-28T14:48:43+05:30", @@ -415,6 +416,7 @@ tests: "user_agent" : "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36" }, "updated_at" : "2024-09-20T10:13:23+05:30", + "current_total_discounts" : "0.00", "customer_locale" : "en", "processed_at" : "2024-08-28T14:48:43+05:30", "currency" : "INR", @@ -424,6 +426,8 @@ tests: "total_line_items_price" : "2398.00", "total_tax" : "431.64", "total_tip_received" : "0.00", + "current_total_tax" : "180.00", + "current_total_price" : "1180.00", "financial_status" : "partially_paid", "name" : "#1002", "customer" : { @@ -840,13 +844,13 @@ tests: order_number: 1002 presentment_currency: "INR" processed_at: "2024-08-28T14:48:43+05:30" - subtotal_price: "2398.00" + subtotal_price: "1000.00" taxes_included: false total_discounts: "0.00" total_line_items_price: "2398.00" total_outstanding: "1296.82" - total_price: "2829.64" - total_tax: "431.64" + total_price: "1180.00" + total_tax: "180.00" total_tip_received: "0.00" total_weight: 600 updated_at: "2024-09-20T10:13:23+05:30" @@ -858,6 +862,7 @@ tests: { "confirmation_number" : "L5MIX0PUW", "fulfillment_status" : "fulfilled", + "current_subtotal_price" : "1000.00", "total_outstanding" : "1296.82", "order_number" : 1002, "created_at" : "2024-08-28T14:48:43+05:30", @@ -1235,6 +1240,7 @@ tests: "user_agent" : "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36" }, "updated_at" : "2024-09-20T10:13:23+05:30", + "current_total_discounts" : "0.00", "customer_locale" : "en", "processed_at" : "2024-08-28T14:48:43+05:30", "currency" : "INR", @@ -1244,6 +1250,8 @@ tests: "total_line_items_price" : "2398.00", "total_tax" : "431.64", "total_tip_received" : "0.00", + "current_total_tax" : "180.00", + "current_total_price" : "1180.00", "financial_status" : "partially_paid", "name" : "#1002", "customer" : { diff --git a/shopify/images/shopify_customer_overview.png b/shopify/images/shopify_customer_overview.png index 9f09273bd629b..f526ce805d3fc 100644 Binary files a/shopify/images/shopify_customer_overview.png and b/shopify/images/shopify_customer_overview.png differ diff --git a/shopify/images/shopify_order_overview.png b/shopify/images/shopify_order_overview.png index 17ba598b47a06..028c62c2a510b 100644 Binary files a/shopify/images/shopify_order_overview.png and b/shopify/images/shopify_order_overview.png differ diff --git a/shopify/images/shopify_product_overview.png b/shopify/images/shopify_product_overview.png index 65e7d45d146dd..cad6d15640143 100644 Binary files a/shopify/images/shopify_product_overview.png and b/shopify/images/shopify_product_overview.png differ