Cross-border Ecommerce Performance

Starting with two batches of structured exports, unify Amazon, Shopify, Meta Ads, and SKU costs in a reusable, traceable dataset and profit dashboard.

7 tables1,344 rows2 import batches
See how it was built
Real workflow

From scattered exports to one profit model

The agent identifies data grain first, then preserves revenue, refunds, cost, and ad spend as reusable business context.

From scattered exports to one profit model

I uploaded the first-week ecommerce exports. Help me analyze them.

I checked the uploaded first-week workbooks and mapped the source structure across Amazon, Shopify, Meta Ads, and SKU costs.

First-week files inspected:

  • Amazon_US_Orders_2026-05-18_to_2026-07-12.xlsx: 302 raw rows, 301 rows after exact deduplication.
  • Amazon_US_Returns_2026-05-25_to_2026-07-12.xlsx: 23 rows.
  • Internal_SKU_Costs.xlsx: 8 SKU cost rows.
  • Meta_Ads_Daily_2026-05-18_to_2026-07-12.xlsx: 168 rows.
  • Shopify_Orders_2026-05-18_to_2026-07-12.xlsx: 252 raw line rows, 251 rows after exact deduplication, representing 199 unique Shopify orders.

The files can support a cross-border ecommerce performance dataset covering revenue, refunds, SKU costs, gross profit, and Meta Ads efficiency. The main data modeling point is that Shopify order-level financials need to be separated from Shopify line items, otherwise order totals will be double-counted when analyzing SKU-level performance.


Organize it into a GoalfyData dataset.

I will build the ecommerce performance dataset from the structured exports and keep the business definitions inside GoalfyData so later analysis and dashboards reuse the same logic.

Confirmed dataset:

Cross-border Ecommerce Performance
Dataset ID: lw1h9uzctm1h
Schema: uds_lw1h9uzctm1h
Created: 2026-07-23T13:30:27.443Z
Source type: manual
Source files: first-week ecommerce exports covering 2026-05-18 to 2026-07-12

The data represents a cross-border ecommerce operating scenario across:

  • Shopify orders
  • Shopify order lines
  • Amazon order lines
  • Amazon returns
  • SKU costs
  • Meta Ads daily performance

The goal is to show how GoalfyData solves recurring ecommerce analysis problems such as inconsistent metric definitions, unclear profit, refund leakage, SKU-level COGS, and ad-efficiency diagnosis.


Show me the structure of the dataset.

Dataset Structure
Cross-border Ecommerce Performance
ID: lw1h9uzctm1h
Schema: uds_lw1h9uzctm1h
Source: manual import from ecommerce exports
Mode: manual import / direct dataset edits; no Managed Refresh schedule is enabled for these tables

Tables

cross_border_ecom_sku_costs — 8 rows
Primary key: sku

columntypenullablemeaning
skutextnonormalized upper-case product identifier used as the product join key
product_nametextnoproduct display name
categorytextnointernal product category
unit_cost_usdnumericnoproduct unit cost in USD
effective_fromdatenodate from which this cost record applies
activebooleannowhether the SKU cost record is active

cross_border_ecom_amazon_order_lines — 344 rows
Primary key: amazon_order_item_id

columntypenullablemeaning
amazon_order_idtextnoAmazon order identifier
amazon_order_item_idtextnoAmazon order-line key after deduplication
purchase_datetimestampnoorder purchase timestamp
order_statustextnoAmazon order status
fulfillment_channeltextnoAmazon fulfillment channel
sales_channeltextnoAmazon sales channel
skutextnonormalized SKU used to join SKU costs
asintextnoAmazon ASIN
item_statustextnoAmazon item status
quantityintegernounits sold
currencytextnotransaction currency
item_pricenumericnoAmazon item price
shipping_pricenumericnoshipping amount charged
item_promotion_discountnumericnoitem-level promotion discount
ship_promotion_discountnumericnoshipping-level promotion discount
ship_countrytextnoshipping destination country

cross_border_ecom_amazon_returns — 28 rows
Primary key: amazon_order_item_id

columntypenullablemeaning
return_request_datetimestampnoreturn request timestamp
amazon_order_idtextnoAmazon order identifier
amazon_order_item_idtextnoAmazon order item identifier and return key
skutextnonormalized SKU used to join SKU costs
return_quantityintegernoreturned unit quantity
return_reasontextnoreturn reason reported by Amazon
return_statustextnoAmazon return workflow status
refund_amountnumericnorefund amount
currencytextnorefund currency

cross_border_ecom_shopify_orders — 219 rows
Primary key: name

columntypenullablemeaning
nametextnoShopify order name and order-level key
created_attimestampnoShopify order creation timestamp
financial_statustextnopayment/refund financial status
fulfillment_statustextnofulfillment status
currencytextnoorder currency
subtotalnumericnoorder subtotal amount
shippingnumericnoshipping amount
taxesnumericnotax amount
totalnumericnoShopify total order amount
discount_amountnumericnodiscount amount
refunded_amountnumericnorefunded amount
refunded_attimestampyesrefund timestamp when present
sourcetextnosource or channel
shipping_countrytextnodestination country
tagstextyesShopify order tags

cross_border_ecom_shopify_order_lines — 277 rows
Primary key: lineitem_id

columntypenullablemeaning
nametextnoShopify order name joining to order financials
lineitem_idtextnoShopify line-item key after deduplication
created_attimestampnoorder creation timestamp
financial_statustextnofinancial status
fulfillment_statustextnofulfillment status
currencytextnoline currency
lineitem_quantityintegernounits on the line item
lineitem_nametextnoproduct line-item name
lineitem_pricenumericnoline unit price
lineitem_skutextnonormalized SKU used to join SKU costs
sourcetextnosource or channel
shipping_countrytextnodestination country
tagstextyesShopify order tags

cross_border_ecom_meta_ads_daily — 189 rows
Primary key: reporting_starts, campaign_name, ad_set_name

columntypenullablemeaning
reporting_startsdatenoreport start date
reporting_endsdatenoreport end date
campaign_nametextnoMeta campaign name
ad_set_nametextnoMeta ad set name
deliverytextnocampaign delivery status
attribution_settingtextnoMeta attribution window
resultsintegernoreported website purchases count
result_indicatortextnoresult type label
reachintegernoMeta reach
impressionsintegernoMeta impressions
link_clicksintegernolink clicks
amount_spent_usdnumericnoMeta spend in USD
purchasesintegernoattributed purchase count
purchase_conversion_valuenumericnoattributed purchase value in USD
ctr_link_click_through_ratenumericnolink click-through rate
cpc_cost_per_link_clicknumericnocost per link click
purchase_roas_return_on_ad_spendnumericnoMeta-reported purchase ROAS

business_rules — 8 rows
Primary key: rule_key

columntypenullablemeaning
rule_keytextnoapplication-facing rule key
rule_grouptextyesrule group
label_displaytextyesdisplay label
labeltextyesEnglish label
valuejsonbyesstructured rule value
definition_displaytextyesdisplay definition
definitiontextyesEnglish definition
enabledbooleanyeswhether the dashboard rule is active
updated_attimestamptzyesupdate timestamp

Relations

  • cross_border_ecom_shopify_order_lines.namecross_border_ecom_shopify_orders.name
  • cross_border_ecom_shopify_order_lines.lineitem_skucross_border_ecom_sku_costs.sku
  • cross_border_ecom_amazon_order_lines.skucross_border_ecom_sku_costs.sku
  • cross_border_ecom_amazon_returns.amazon_order_item_idcross_border_ecom_amazon_order_lines.amazon_order_item_id
  • cross_border_ecom_amazon_returns.skucross_border_ecom_sku_costs.sku
  • cross_border_ecom_meta_ads_daily.reporting_starts can be compared with cross_border_ecom_shopify_orders.created_at at date grain
  • cross_border_ecom_meta_ads_daily.reporting_starts can be compared with cross_border_ecom_amazon_order_lines.purchase_date at date grain

Rules

  • Preserve Shopify order-level financials separately from Shopify line items to avoid double-counting order totals.
  • Normalize SKU fields before joining platforms.
  • Amazon gross revenue = item price + shipping price - item promotion discount - shipping promotion discount.
  • Shopify gross revenue = subtotal + shipping - discount amount.
  • Net revenue = gross revenue - refunds.
  • COGS = units sold × unit_cost_usd.
  • Gross profit before ads = net revenue - COGS.
  • Contribution after ads = gross profit before ads - Meta spend.
  • Meta Ads should be compared at date/campaign grain, not treated as direct order-level attribution.

Help me create a dashboard.

Done. I created and deployed a dashboard app for this dataset.

App: ecommerce-performance-dashboard
App ID: ecommerce-performance-de-a8898e649df8
URL: https://app-814c7318104b-ecommerce-performance-de-a8898e649df8.goalfydata.app
Current deploy: FzcLp4mpXYuIYklA0dEPvQ
Current visual direction: dark AI ops control room
Bound dataset: Cross-border Ecommerce Performance (lw1h9uzctm1h)

The current dashboard includes:

  • Live contribution trace
  • KPI telemetry strip
  • Profit waterfall
  • Category margin terminal
  • Meta Ads efficiency
  • Source contribution
  • Diagnostic console with Signals, Refunds, and Rules

Verification passed:

  • Frontend smoke test
  • Frontend production build
  • Backend TypeScript build
  • GoalfyData preflight
  • Production dependency audit
  • Deployment status online

Analyze it using the first-week data.

Analysis complete. I queried the dataset after the first-week load and used the governed profit logic.

First-week Dataset Snapshot

  • Time range: 2026-05-18 to 2026-07-12
  • Shopify orders: 199
  • Shopify order lines: 251
  • Amazon order lines: 301
  • Amazon returns: 23
  • Meta Ads daily rows: 168
  • SKU cost records: 8

First-week Metric Summary

MetricValue
Total net revenue$17,400.11
Total COGS$4,907.00
Total refunds$1,338.65
Meta spend$27,967.94
Gross profit before ads$12,493.11
Contribution after ads-$15,474.83
Meta ROAS1.65
Blended MER0.62

First-week Findings

  1. The first-week data already shows the core profit problem.
    Net revenue and gross profit exist, but Meta spend is larger than gross profit before ads, so contribution after ads is negative.

  2. The analysis is useful because it makes the metric path visible.
    It separates revenue, refunds, COGS, ad spend, and contribution instead of collapsing everything into one revenue chart.

  3. The next useful step is to update the dataset with the following week.
    Adding the July 13-19 exports can show whether the same profit pattern continues after the first-week baseline.


I uploaded the second-week update files for July 13-19. Please update the existing ecommerce dataset with these new weekly exports.

Done. I updated the ecommerce dataset with the second-week exports and validated the full dataset.

Second-week files processed:

  • UPDATE_Amazon_US_Orders_2026-07-13_to_2026-07-19.xlsx: 44 raw rows, 43 rows after exact deduplication.
  • UPDATE_Amazon_US_Returns_2026-07-13_to_2026-07-19.xlsx: 5 rows.
  • UPDATE_Meta_Ads_Daily_2026-07-13_to_2026-07-19.xlsx: 21 rows.
  • UPDATE_Shopify_Orders_2026-07-13_to_2026-07-19.xlsx: 26 line rows, representing 20 unique Shopify orders.

Tables after the second-week update:

  • cross_border_ecom_sku_costs: 8 rows
  • cross_border_ecom_amazon_order_lines: 344 rows
  • cross_border_ecom_amazon_returns: 28 rows
  • cross_border_ecom_shopify_orders: 219 rows
  • cross_border_ecom_shopify_order_lines: 277 rows
  • cross_border_ecom_meta_ads_daily: 189 rows

The original creation task was:

4j3acnzwajfi
Task name: Build ecommerce dataset tables
Created: 2026-07-23 21:50 Asia/Shanghai
Task description: Create and load structured ecommerce base tables from Amazon, Shopify, Meta Ads, and SKU cost exports into the confirmed GoalfyData dataset.

Validation and persistence completed:

  • Tables were created and imported through GoalfyData data-plane operations.
  • Metadata was registered for all six original ecommerce tables.
  • Logical relations were saved.
  • Governance rules were saved.
  • Usage guide was written.
  • Initial import task completion was recorded at 2026-07-23 22:01 Asia/Shanghai.

The second update task was:

utnydv4cpu9g
Task name: Update July 13-19 ecommerce weekly exports
Created: 2026-07-24 10:30 Asia/Shanghai
Update scope: deduplication, SKU normalization, late refund preservation, import validation, and post-update checks.
Task completion was recorded at 2026-07-24 10:33 Asia/Shanghai.

Cleaning rules recorded at creation:

  • Exact duplicate export rows were removed before import for Amazon order lines and Shopify order lines.
  • This removed 1 Amazon row and 1 Shopify line row in the initial load.
  • SKU join fields were trimmed and normalized to upper case before import.

Analyze this dataset.

Analysis complete. I queried the live GoalfyData dataset and found:

Dataset Snapshot

  • Time range: 2026-05-18 to 2026-07-19
  • Shopify orders: 219
  • Shopify order lines: 277
  • Amazon order lines: 344
  • Amazon returns: 28
  • Meta Ads daily rows: 189
  • SKU cost records: 8
  • Dashboard-facing business rules: 8
  • Platform governance rules: 19
  • Logical relations: 7

Metric Summary

MetricValue
Total net revenue$19,383.28
Total COGS$5,467.20
Total refunds$1,536.85
Meta spend$31,724.64
Gross profit before ads$13,916.08
Contribution after ads-$17,808.56
Meta ROAS1.66
Blended MER0.61

Category Margin Snapshot

CategoryUnitsEstimated salesCOGSGross profitGross margin
Travel Organization88$2,386.00$569.60$1,816.4076.1%
Electronics40$1,680.00$480.00$1,200.0071.4%
Travel Security73$1,432.00$331.40$1,100.6076.9%
Drinkware40$1,440.00$380.00$1,060.0073.6%
Travel Comfort34$1,326.00$387.60$938.4070.8%
Bags31$837.00$220.10$616.9073.7%

Quality Checks

  • Primary-key duplicate checks returned 0 issues for Amazon order lines, Amazon returns, Shopify orders, Shopify order lines, SKU costs, and Meta Ads daily rows.
  • Key-column null checks returned 0 issues.
  • The dataset has consistent date coverage across Shopify, Amazon, and Meta Ads: 2026-05-18 to 2026-07-19.

Key Findings

  1. Revenue exists, but contribution is negative.
    The dataset shows $19.4K in net revenue and $13.9K gross profit before ads, but Meta spend of $31.7K pushes contribution after ads to -$17.8K.

  2. The problem is not SKU margin alone.
    Category-level Shopify margins are high before ad spend, mostly around 70% to 77%. This means the immediate diagnosis is not simply “products have no margin”; the ad-spend layer is the biggest pressure point in this sample.

  3. Refunds are material but not the main loss driver.
    Refunds reduce revenue by $1.5K. They matter for revenue quality and SKU diagnosis, but they are much smaller than Meta spend.

  4. Meta Ads must not be over-attributed.
    The dataset explicitly stores Meta Ads at daily campaign/ad set grain. It can support ROAS, blended MER, and date-level comparison, but not direct order-level attribution.

  5. The dataset shows GoalfyData’s governance value.
    Profit, COGS, refund deduction, valid order logic, SKU normalization, and attribution boundaries are persisted as rules, so future agents and dashboards can reuse the same definitions.


Share this dataset with u***@example.com. Do not share the dashboard-facing business rules table.

Done. I shared Cross-border Ecommerce Performance with u***@example.com.

Access scope:

  • Included: cross_border_ecom_sku_costs
  • Included: cross_border_ecom_amazon_order_lines
  • Included: cross_border_ecom_amazon_returns
  • Included: cross_border_ecom_shopify_orders
  • Included: cross_border_ecom_shopify_order_lines
  • Included: cross_border_ecom_meta_ads_daily
  • Excluded: business_rules

Share ID:
Status: pending
Permission: read-only

The invitation email was sent. If they do not see it, ask them to check spam/junk.


Share this dashboard with v***@example.com.

Done. I shared the ecommerce performance dashboard with v***@example.com.

Dashboard: ecommerce-performance-dashboard
Visibility: specified email only
Permission: read-only
Status: pending
Email sent: yes

The dashboard stays bound to Cross-border Ecommerce Performance (lw1h9uzctm1h), so the recipient sees the same governed profit, refund, SKU margin, and Meta Ads efficiency definitions.

Share code:


Share this dataset with w***@example.com.

Done. I shared Cross-border Ecommerce Performance with w***@example.com.

Access scope:

  • Included: full dataset

Status: pending
Permission: read-only

The invitation email was sent. If they do not see it, ask them to check spam/junk.



Governed data asset

Keep operating definitions inside the dataset

Orders, lines, refunds, costs, and paid media retain their original grain, then stable relationships and business rules assemble the profit model.

DatasetCross-border Ecommerce Performance
Ready

Review core tables, grain, and keys. Hover over another tab to switch views.

cross_border_ecom_amazon_order_linesAmazon order-line revenue and fulfillment
344 rows · primary key: amazon_order_item_id
cross_border_ecom_shopify_ordersOrder-level totals kept separate from line items
219 rows · primary key: name
cross_border_ecom_meta_ads_dailySpend, purchases, conversion value and ROAS
189 rows · daily campaign grain
Generated app

Open the live operations dashboard

The summary highlights core operating metrics. Open the current public, read-only app in a new tab for the full experience.

Take the result with you

Add “Cross-border Ecommerce Performance” to your account

Enter your email and we’ll send invitations for this dataset and app. Opening an email verifies your address; a new account is created automatically, or you’re signed in to an existing one.

Accepting the dataset uses 1 dataset slot. Your existing account limit still applies.