JSData & Media Start a project

← All connectors

Schema · Entity relationship diagram

TikTok Shop tables and relationships

Orders and finance (statements, fee-level transactions, payouts) with full history, shop, product and SKU analytics, videos, LIVEs and bestseller leaderboards.

Live18 tables · 9 relationships
ConnectSign in and approve
MarketsUS, UK, Germany, France, Spain, Italy
DestinationsAmazon Redshift, Google BigQuery, Snowflake, PostgreSQL, Amazon S3
  • orders has one row per order line (key line_item_id). Order-level amounts repeat on every line, so filter is_order_first_line = 1 before summing order_* columns.
  • The bestselling_* tables are platform-wide top-100 leaderboards across all of TikTok Shop, so every shop gets the same rows.
  • Affiliate orders, samples and creator tables are on the TikTok Shop Affiliate page.
SHOP & PRODUCT ANALYTICSVIDEOS & LIVEBESTSELLERS (PLATFORM-WIDE)FINANCEproduct_performance_daily.product_id joins orders.product_idsku_performance_daily.sku_id joins orders.sku_idsku_performance_daily.product_id,date joins product_performance_daily.product_id,datefinance_statement_transactions.statement_id → finance_statements.statement_idfinance_statements.payment_id → finance_payments.payment_idfinance_statement_transactions.order_id joins orders.order_idfinance_unsettled_transactions.order_id joins orders.order_idvideo_performance_by_video.video_id → videos.video_idlive_product_performance.live_id → live_performance.live_idsku_performance_dailysku_performance_daily9pk VARCHAR(32) · primary keypkvarchardate DATE · → product_performance_daily.product_id,datedatedatesku_id VARCHAR(64) · → orders.sku_idsku_idvarcharproduct_id VARCHAR(64) · → product_performance_daily.product_id,dateproduct_idvarcharcurrency VARCHAR(8)currencyvarchargmv DECIMAL(18,4)gmvdecimalsku_orders INTEGERsku_ordersintunits_sold INTEGERunits_soldint_synced_at TIMESTAMP_synced_attimestampproduct_performance_dailyproduct_performance_daily9pk VARCHAR(32) · primary keypkvarchardate DATEdatedateproduct_id VARCHAR(64) · → orders.product_idproduct_idvarcharcurrency VARCHAR(8)currencyvarchargmv DECIMAL(18,4)gmvdecimalorders INTEGERordersintunits_sold INTEGERunits_soldintclick_through_rate DECIMAL(10,6)click_through_ratedecimal_synced_at TIMESTAMP_synced_attimestampshop_performance_dailyshop_performance_daily29date DATE · primary keydatedatecurrency VARCHAR(8)currencyvarchargmv DECIMAL(18,4)gmvdecimalorders INTEGERordersintsku_orders INTEGERsku_ordersintunits_sold INTEGERunits_soldintbuyers INTEGERbuyersintavg_order_value DECIMAL(18,4)avg_order_valuedecimalrefunds DECIMAL(18,4)refundsdecimalcancellations_and_returns INTEGERcancellations_and_returnsintproduct_impressions BIGINTproduct_impressionsbigintproduct_page_views BIGINTproduct_page_viewsbigintavg_product_page_visitors BIGINTavg_product_page_visitorsbigintgmv_live DECIMAL(18,4)gmv_livedecimalgmv_video DECIMAL(18,4)gmv_videodecimalgmv_product_card DECIMAL(18,4)gmv_product_carddecimalimpressions_live BIGINTimpressions_livebigintimpressions_video BIGINTimpressions_videobigintimpressions_product_card BIGINTimpressions_product_cardbigintpage_views_live BIGINTpage_views_livebigintpage_views_video BIGINTpage_views_videobigintpage_views_product_card BIGINTpage_views_product_cardbigintbuyers_live INTEGERbuyers_liveintbuyers_video INTEGERbuyers_videointbuyers_product_card INTEGERbuyers_product_cardintvisitors_live BIGINTvisitors_livebigintvisitors_video BIGINTvisitors_videobigintvisitors_product_card BIGINTvisitors_product_cardbigint_synced_at TIMESTAMP_synced_attimestampordersorders59line_item_id VARCHAR(64) · primary keyline_item_idvarcharorder_id VARCHAR(64)order_idvarcharproduct_id VARCHAR(64)product_idvarcharsku_id VARCHAR(64)sku_idvarcharorder_status VARCHAR(64)order_statusvarcharorder_type VARCHAR(64)order_typevarcharbuyer_user_id VARCHAR(64)buyer_user_idvarcharcreate_time_utc TIMESTAMPcreate_time_utctimestamporder_date_pt DATEorder_date_ptdateupdate_time_utc TIMESTAMPupdate_time_utctimestamppaid_time_utc TIMESTAMPpaid_time_utctimestampdelivery_time_utc TIMESTAMPdelivery_time_utctimestampcancel_reason VARCHAR(512)cancel_reasonvarcharis_cod SMALLINTis_codsmallintis_sample_order SMALLINTis_sample_ordersmallintfulfillment_type VARCHAR(64)fulfillment_typevarchardelivery_option_name VARCHAR(256)delivery_option_namevarcharshipping_provider VARCHAR(256)shipping_providervarcharpayment_method_name VARCHAR(128)payment_method_namevarcharwarehouse_id VARCHAR(64)warehouse_idvarcharseller_note VARCHAR(2048)seller_notevarcharbuyer_message VARCHAR(2048)buyer_messagevarcharcurrency VARCHAR(8)currencyvarcharorder_total_amount DECIMAL(18,4)order_total_amountdecimalorder_sub_total DECIMAL(18,4)order_sub_totaldecimalorder_shipping_fee DECIMAL(18,4)order_shipping_feedecimalorder_seller_discount DECIMAL(18,4)order_seller_discountdecimalorder_platform_discount DECIMAL(18,4)order_platform_discountdecimalorder_original_total_product_price DECIMAL(18,4)order_original_total_product_pricedecimalorder_original_shipping_fee DECIMAL(18,4)order_original_shipping_feedecimalorder_shipping_fee_seller_discount DECIMAL(18,4)order_shipping_fee_seller_discountdecimalorder_shipping_fee_platform_discount DECIMAL(18,4)order_shipping_fee_platform_discountdecimalorder_tax DECIMAL(18,4)order_taxdecimalrecipient_name VARCHAR(256)recipient_namevarcharrecipient_phone VARCHAR(64)recipient_phonevarcharfull_address VARCHAR(1024)full_addressvarcharpostal_code VARCHAR(32)postal_codevarcharregion_code VARCHAR(8)region_codevarcharcountry VARCHAR(128)countryvarcharstate VARCHAR(128)statevarcharcounty VARCHAR(128)countyvarcharcity VARCHAR(128)cityvarcharproduct_name VARCHAR(1024)product_namevarcharseller_sku VARCHAR(256)seller_skuvarcharsku_name VARCHAR(512)sku_namevarcharsku_type VARCHAR(64)sku_typevarcharline_original_price DECIMAL(18,4)line_original_pricedecimalline_sale_price DECIMAL(18,4)line_sale_pricedecimalline_seller_discount DECIMAL(18,4)line_seller_discountdecimalline_platform_discount DECIMAL(18,4)line_platform_discountdecimalpackage_id VARCHAR(64)package_idvarcharpackage_status VARCHAR(64)package_statusvarcharline_display_status VARCHAR(64)line_display_statusvarcharline_shipping_provider_name VARCHAR(256)line_shipping_provider_namevarcharline_tracking_number VARCHAR(128)line_tracking_numbervarcharorder_line_count INTEGERorder_line_countintis_order_first_line SMALLINTis_order_first_linesmallintshop_id VARCHAR(64)shop_idvarchar_synced_at TIMESTAMP_synced_attimestampfinance_unsettled_transactions — SNAPSHOT of transactions not yet settled (orders created since 2025-01-01), with TikTok's ESTIMATED amounts. Each run replaces the shop's rows (upsert key shop_id); once a transaction settles it leavefinance_unsettled_transactions32shop_id VARCHAR(64) · primary keyshop_idvarcharorder_id VARCHAR(64) · primary key · → orders.order_idorder_idvarchartransaction_id VARCHAR(64)transaction_idvarchartransaction_type VARCHAR(64)transaction_typevarcharstatus VARCHAR(32)statusvarcharadjustment_id VARCHAR(64)adjustment_idvarcharadjustment_order_id VARCHAR(64)adjustment_order_idvarcharorder_create_time_utc TIMESTAMPorder_create_time_utctimestamporder_delivery_time_utc TIMESTAMPorder_delivery_time_utctimestampestimated_settlement_time_utc TIMESTAMPestimated_settlement_time_utctimestampestimated_settlement_note VARCHAR(256)estimated_settlement_notevarcharunsettled_reason VARCHAR(512)unsettled_reasonvarcharcurrency VARCHAR(8)currencyvarcharest_settlement_amount DECIMAL(18,4)est_settlement_amountdecimalest_revenue_amount DECIMAL(18,4)est_revenue_amountdecimalest_shipping_cost_amount DECIMAL(18,4)est_shipping_cost_amountdecimalest_fee_tax_amount DECIMAL(18,4)est_fee_tax_amountdecimalest_adjustment_amount DECIMAL(18,4)est_adjustment_amountdecimalgross_sales_amount DECIMAL(18,4)gross_sales_amountdecimalgross_sales_refund_amount DECIMAL(18,4)gross_sales_refund_amountdecimalseller_discount_amount DECIMAL(18,4)seller_discount_amountdecimalseller_discount_refund_amount DECIMAL(18,4)seller_discount_refund_amountdecimalactual_shipping_fee_amount DECIMAL(18,4)actual_shipping_fee_amountdecimalshipping_fee_discount_amount DECIMAL(18,4)shipping_fee_discount_amountdecimalcustomer_paid_shipping_fee_amount DECIMAL(18,4)customer_paid_shipping_fee_amountdecimalplatform_commission_amount DECIMAL(18,4)platform_commission_amountdecimalreferral_fee_amount DECIMAL(18,4)referral_fee_amountdecimalaffiliate_commission_amount DECIMAL(18,4)affiliate_commission_amountdecimalaffiliate_partner_commission_amount DECIMAL(18,4)affiliate_partner_commission_amountdecimalaffiliate_ads_commission_amount DECIMAL(18,4)affiliate_ads_commission_amountdecimalbreakdown_json VARCHAR(8000)breakdown_jsonvarchar_synced_at TIMESTAMP_synced_attimestampfinance_statement_transactions — One row per transaction in a statement: an ORDER settlement, an adjustment (type = the adjustment policy, e.g. CHARGE_BACK) or a RESERVE movement. Upsert key pk = md5(statement_id|transaction_id). Brefinance_statement_transactions87pk VARCHAR(32) · primary keypkvarcharstatement_id VARCHAR(64) · → finance_statements.statement_idstatement_idvarcharorder_id VARCHAR(64) · → orders.order_idorder_idvarcharstatement_time_utc TIMESTAMPstatement_time_utctimestampstatement_date DATEstatement_datedatetransaction_id VARCHAR(64)transaction_idvarchartransaction_type VARCHAR(64)transaction_typevarcharorder_create_time_utc TIMESTAMPorder_create_time_utctimestampadjustment_id VARCHAR(64)adjustment_idvarcharadjustment_order_id VARCHAR(64)adjustment_order_idvarcharreserve_id VARCHAR(64)reserve_idvarcharreserve_status VARCHAR(32)reserve_statusvarcharassociated_order_id VARCHAR(64)associated_order_idvarcharestimated_release_time_utc TIMESTAMPestimated_release_time_utctimestampcurrency VARCHAR(8)currencyvarcharsettlement_amount DECIMAL(18,4)settlement_amountdecimalrevenue_amount DECIMAL(18,4)revenue_amountdecimalshipping_cost_amount DECIMAL(18,4)shipping_cost_amountdecimalfee_tax_amount DECIMAL(18,4)fee_tax_amountdecimaladjustment_amount DECIMAL(18,4)adjustment_amountdecimalreserve_amount DECIMAL(18,4)reserve_amountdecimalgross_sales_amount DECIMAL(18,4)gross_sales_amountdecimalgross_sales_refund_amount DECIMAL(18,4)gross_sales_refund_amountdecimalseller_discount_amount DECIMAL(18,4)seller_discount_amountdecimalseller_discount_refund_amount DECIMAL(18,4)seller_discount_refund_amountdecimalother_revenue_amount DECIMAL(18,4)other_revenue_amountdecimalactual_shipping_fee_amount DECIMAL(18,4)actual_shipping_fee_amountdecimalshipping_fee_discount_amount DECIMAL(18,4)shipping_fee_discount_amountdecimalcustomer_paid_shipping_fee_amount DECIMAL(18,4)customer_paid_shipping_fee_amountdecimalreturn_shipping_fee_amount DECIMAL(18,4)return_shipping_fee_amountdecimalfbt_free_shipping_fee_amount DECIMAL(18,4)fbt_free_shipping_fee_amountdecimalfbt_fulfillment_fee_reimbursement_amount DECIMAL(18,4)fbt_fulfillment_fee_reimbursement_amountdecimalshipping_insurance_fee_amount DECIMAL(18,4)shipping_insurance_fee_amountdecimalsignature_confirmation_fee_amount DECIMAL(18,4)signature_confirmation_fee_amountdecimallogistics_service_fee_amount DECIMAL(18,4)logistics_service_fee_amountdecimalother_shipping_amount DECIMAL(18,4)other_shipping_amountdecimaltts_shipping_incentive_amount DECIMAL(18,4)tts_shipping_incentive_amountdecimalfbt_fulfillment_fee_amount DECIMAL(18,4)fbt_fulfillment_fee_amountdecimalfbt_shipping_cost_amount DECIMAL(18,4)fbt_shipping_cost_amountdecimalfbm_shipping_cost_amount DECIMAL(18,4)fbm_shipping_cost_amountdecimalplatform_shipping_fee_discount_amount DECIMAL(18,4)platform_shipping_fee_discount_amountdecimalseller_shipping_fee_discount_amount DECIMAL(18,4)seller_shipping_fee_discount_amountdecimalcustomer_shipping_fee_offset_amount DECIMAL(18,4)customer_shipping_fee_offset_amountdecimalplatform_commission_amount DECIMAL(18,4)platform_commission_amountdecimalreferral_fee_amount DECIMAL(18,4)referral_fee_amountdecimalrefund_administration_fee_amount DECIMAL(18,4)refund_administration_fee_amountdecimaltransaction_fee_amount DECIMAL(18,4)transaction_fee_amountdecimalcredit_card_handling_fee_amount DECIMAL(18,4)credit_card_handling_fee_amountdecimalaffiliate_commission_amount DECIMAL(18,4)affiliate_commission_amountdecimalaffiliate_partner_commission_amount DECIMAL(18,4)affiliate_partner_commission_amountdecimalaffiliate_ads_commission_amount DECIMAL(18,4)affiliate_ads_commission_amountdecimalaffiliate_commission_deposit_amount DECIMAL(18,4)affiliate_commission_deposit_amountdecimalaffiliate_commission_release_amount DECIMAL(18,4)affiliate_commission_release_amountdecimalcofunded_creator_bonus_amount DECIMAL(18,4)cofunded_creator_bonus_amountdecimaltap_shop_ads_commission_amount DECIMAL(18,4)tap_shop_ads_commission_amountdecimalexternal_affiliate_marketing_fee_amount DECIMAL(18,4)external_affiliate_marketing_fee_amountdecimalgmv_max_ad_fee_amount DECIMAL(18,4)gmv_max_ad_fee_amountdecimalgmv_max_coupon_fee_amount DECIMAL(18,4)gmv_max_coupon_fee_amountdecimalsmart_promotion_fee_amount DECIMAL(18,4)smart_promotion_fee_amountdecimalcampaign_period_fee_amount DECIMAL(18,4)campaign_period_fee_amountdecimalflash_sales_service_fee_amount DECIMAL(18,4)flash_sales_service_fee_amountdecimalsfp_service_fee_amount DECIMAL(18,4)sfp_service_fee_amountdecimallive_specials_fee_amount DECIMAL(18,4)live_specials_fee_amountdecimalbonus_cashback_service_fee_amount DECIMAL(18,4)bonus_cashback_service_fee_amountdecimalvoucher_xtra_service_fee_amount DECIMAL(18,4)voucher_xtra_service_fee_amountdecimalcofunded_promotion_service_fee_amount DECIMAL(18,4)cofunded_promotion_service_fee_amountdecimalseller_growth_fee_amount DECIMAL(18,4)seller_growth_fee_amountdecimalepr_pob_service_fee_amount DECIMAL(18,4)epr_pob_service_fee_amountdecimalother_fee_amount DECIMAL(18,4)other_fee_amountdecimalsales_tax_on_fees_amount DECIMAL(18,4)sales_tax_on_fees_amountdecimalvat_amount DECIMAL(18,4)vat_amountdecimalimport_vat_amount DECIMAL(18,4)import_vat_amountdecimalcustoms_duty_amount DECIMAL(18,4)customs_duty_amountdecimalother_tax_amount DECIMAL(18,4)other_tax_amountdecimalcustomer_payment_amount DECIMAL(18,4)customer_payment_amountdecimalcustomer_refund_amount DECIMAL(18,4)customer_refund_amountdecimalplatform_discount_amount DECIMAL(18,4)platform_discount_amountdecimalplatform_discount_refund_amount DECIMAL(18,4)platform_discount_refund_amountdecimalseller_cofunded_discount_amount DECIMAL(18,4)seller_cofunded_discount_amountdecimalseller_cofunded_discount_refund_amount DECIMAL(18,4)seller_cofunded_discount_refund_amountdecimalplatform_cofunded_discount_amount DECIMAL(18,4)platform_cofunded_discount_amountdecimalplatform_cofunded_discount_refund_amount DECIMAL(18,4)platform_cofunded_discount_refund_amountdecimalsales_tax_amount DECIMAL(18,4)sales_tax_amountdecimalretail_delivery_fee_amount DECIMAL(18,4)retail_delivery_fee_amountdecimalbreakdown_json VARCHAR(8000)breakdown_jsonvarcharshop_id VARCHAR(64)shop_idvarchar_synced_at TIMESTAMP_synced_attimestampvideo_performance_by_video — Sales-active videos only, day x video grain (creator attribution).video_performance_by_video14pk VARCHAR(32) · primary keypkvarcharvideo_id VARCHAR(64) · → videos.video_idvideo_idvarchardate DATEdatedateusername VARCHAR(256)usernamevarcharvideo_post_time TIMESTAMPvideo_post_timetimestampcurrency VARCHAR(8)currencyvarchargmv DECIMAL(18,4)gmvdecimalgpm DECIMAL(18,4)gpmdecimalsku_orders INTEGERsku_ordersintitems_sold INTEGERitems_soldintavg_customers INTEGERavg_customersintviews BIGINTviewsbigintclick_through_rate DECIMAL(10,6)click_through_ratedecimal_synced_at TIMESTAMP_synced_attimestamplive_product_performance — Per-LIVE product breakdown (202512). Only the shop's OWN official/ marketing account lives have rows — affiliate creator lives return no data from TikTok. Join live_id to live_performance for session live_product_performance21pk VARCHAR(32) · primary keypkvarcharlive_id VARCHAR(64) · → live_performance.live_idlive_idvarcharproduct_id VARCHAR(64)product_idvarcharproduct_name VARCHAR(1000)product_namevarcharcurrency VARCHAR(8)currencyvarchardirect_gmv DECIMAL(18,4)direct_gmvdecimalavg_price DECIMAL(18,4)avg_pricedecimalsku_orders INTEGERsku_ordersintcreated_sku_orders INTEGERcreated_sku_ordersintmain_orders INTEGERmain_ordersintcustomers INTEGERcustomersintitems_sold INTEGERitems_soldintpayment_rate DECIMAL(10,6)payment_ratedecimaladd_to_cart_count INTEGERadd_to_cart_countintproduct_impressions BIGINTproduct_impressionsbigintproduct_clicks BIGINTproduct_clicksbigintctr DECIMAL(10,6)ctrdecimalmain_order_ctor DECIMAL(10,6)main_order_ctordecimalsku_order_ctor DECIMAL(10,6)sku_order_ctordecimalwatch_gpm DECIMAL(18,4)watch_gpmdecimal_synced_at TIMESTAMP_synced_attimestampvideo_performance_daily — Video & photo overview, daily (202509 shop_videos/overview_performance). Matches Seller Center's "Video & photo" view (photo-inclusive scope).video_performance_daily9date DATE · primary keydatedatecurrency VARCHAR(8)currencyvarchargmv DECIMAL(18,4)gmvdecimalsku_orders INTEGERsku_ordersintavg_customers INTEGERavg_customersintproduct_impressions BIGINTproduct_impressionsbigintproduct_clicks BIGINTproduct_clicksbigintclick_through_rate DECIMAL(10,6)click_through_ratedecimal_synced_at TIMESTAMP_synced_attimestampvideos — Every video ever posted (identity only; the date window on the source endpoint scopes metrics, not membership — so this is complete history). "Video posts per day/week" = COUNT(*) grouped on video_posvideos7video_id VARCHAR(64) · primary keyvideo_idvarcharusername VARCHAR(256)usernamevarchartitle VARCHAR(1000)titlevarcharvideo_post_time TIMESTAMPvideo_post_timetimestampduration_seconds INTEGERduration_secondsintproduct_ids VARCHAR(2000)product_idsvarchar_synced_at TIMESTAMP_synced_attimestamplive_performance — One row per LIVE stream session (zero-sale sessions kept — session counts are a metric). Rates stored as fractions (0.0571 = 5.71%).live_performance17live_id VARCHAR(64) · primary keylive_idvarcharusername VARCHAR(256)usernamevarchartitle VARCHAR(500)titlevarcharstart_time TIMESTAMPstart_timetimestampend_time TIMESTAMPend_timetimestampcurrency VARCHAR(8)currencyvarchargmv DECIMAL(18,4)gmvdecimalgmv_24h DECIMAL(18,4)gmv_24hdecimalsku_orders INTEGERsku_ordersintcreated_sku_orders INTEGERcreated_sku_ordersintitems_sold INTEGERitems_soldintcustomers INTEGERcustomersintavg_price DECIMAL(18,4)avg_pricedecimalclick_to_order_rate DECIMAL(10,6)click_to_order_ratedecimalproducts_added INTEGERproducts_addedintdifferent_products_sold INTEGERdifferent_products_soldint_synced_at TIMESTAMP_synced_attimestampfinance_statements — One row per statement (a shop can get 2+ per day: orders + adjustments). Upsert key statement_id; re-pulled over a trailing window so payment status/payment_id updates land.finance_statements15statement_id VARCHAR(64) · primary keystatement_idvarcharpayment_id VARCHAR(64) · → finance_payments.payment_idpayment_idvarcharstatement_time_utc TIMESTAMPstatement_time_utctimestampstatement_date DATEstatement_datedatecurrency VARCHAR(8)currencyvarcharsettlement_amount DECIMAL(18,4)settlement_amountdecimalrevenue_amount DECIMAL(18,4)revenue_amountdecimalnet_sales_amount DECIMAL(18,4)net_sales_amountdecimalfee_amount DECIMAL(18,4)fee_amountdecimalshipping_cost_amount DECIMAL(18,4)shipping_cost_amountdecimaladjustment_amount DECIMAL(18,4)adjustment_amountdecimalpayment_status VARCHAR(32)payment_statusvarcharpayment_time_utc TIMESTAMPpayment_time_utctimestampshop_id VARCHAR(64)shop_idvarchar_synced_at TIMESTAMP_synced_attimestampfinance_payments — Payouts to the seller's bank account. Upsert key payment_id.finance_payments14payment_id VARCHAR(64) · primary keypayment_idvarcharcreate_time_utc TIMESTAMPcreate_time_utctimestamppaid_time_utc TIMESTAMPpaid_time_utctimestampstatus VARCHAR(32)statusvarcharamount DECIMAL(18,4)amountdecimalcurrency VARCHAR(8)currencyvarcharsettlement_amount DECIMAL(18,4)settlement_amountdecimalsettlement_currency VARCHAR(8)settlement_currencyvarcharamount_before_exchange DECIMAL(18,4)amount_before_exchangedecimalcurrency_before_exchange VARCHAR(8)currency_before_exchangevarcharexchange_rate DECIMAL(18,6)exchange_ratedecimalbank_account_last4 VARCHAR(4)bank_account_last4varcharshop_id VARCHAR(64)shop_idvarchar_synced_at TIMESTAMP_synced_attimestampbestselling_creatorsbestselling_creators13pk VARCHAR(32) · primary keypkvarchardate DATEdatedatetime_slot VARCHAR(4)time_slotvarcharrank INTEGERrankintusername VARCHAR(256)usernamevarcharnick_name VARCHAR(256)nick_namevarcharopen_id VARCHAR(128)open_idvarcharfollowers_count BIGINTfollowers_countbigintlikes_count BIGINTlikes_countbigintcurrency VARCHAR(8)currencyvarchargmv_low DECIMAL(18,4)gmv_lowdecimalgmv_high DECIMAL(18,4)gmv_highdecimal_synced_at TIMESTAMP_synced_attimestampfinance_withdrawals — Seller balance movements: SETTLE (statement credited), WITHDRAW (payout), TRANSFER (platform subsidy/deduction), REVERSE (failed payout). Upsert key withdrawal_id.finance_withdrawals8withdrawal_id VARCHAR(64) · primary keywithdrawal_idvarcharwithdrawal_type VARCHAR(32)withdrawal_typevarcharstatus VARCHAR(32)statusvarcharamount DECIMAL(18,4)amountdecimalcurrency VARCHAR(8)currencyvarcharcreate_time_utc TIMESTAMPcreate_time_utctimestampshop_id VARCHAR(64)shop_idvarchar_synced_at TIMESTAMP_synced_attimestampbestselling_livesbestselling_lives15pk VARCHAR(32) · primary keypkvarchardate DATEdatedatetime_slot VARCHAR(4)time_slotvarcharrank INTEGERrankintlive_id VARCHAR(64)live_idvarcharcreator_name VARCHAR(256)creator_namevarcharcreator_nick_name VARCHAR(256)creator_nick_namevarcharopen_id VARCHAR(128)open_idvarchartitle VARCHAR(500)titlevarcharstart_time TIMESTAMPstart_timetimestampduration_seconds INTEGERduration_secondsintcurrency VARCHAR(8)currencyvarchargmv_low DECIMAL(18,4)gmv_lowdecimalgmv_high DECIMAL(18,4)gmv_highdecimal_synced_at TIMESTAMP_synced_attimestampbestselling_productsbestselling_products10pk VARCHAR(32) · primary keypkvarchardate DATEdatedatetime_slot VARCHAR(4)time_slotvarcharrank INTEGERrankintproduct_id VARCHAR(64)product_idvarcharproduct_name VARCHAR(1000)product_namevarcharcurrency VARCHAR(8)currencyvarchargmv_low DECIMAL(18,4)gmv_lowdecimalgmv_high DECIMAL(18,4)gmv_highdecimal_synced_at TIMESTAMP_synced_attimestampbestselling_videosbestselling_videos16pk VARCHAR(32) · primary keypkvarchardate DATEdatedatetime_slot VARCHAR(4)time_slotvarcharrank INTEGERrankintvideo_id VARCHAR(64)video_idvarcharnick_name VARCHAR(256)nick_namevarcharduration_seconds INTEGERduration_secondsintlikes BIGINTlikesbigintcomments BIGINTcommentsbigintpublish_time TIMESTAMPpublish_timetimestamptop_product_id VARCHAR(64)top_product_idvarchartop_product_name VARCHAR(500)top_product_namevarcharcurrency VARCHAR(8)currencyvarchargmv_low DECIMAL(18,4)gmv_lowdecimalgmv_high DECIMAL(18,4)gmv_highdecimal_synced_at TIMESTAMP_synced_attimestamp
Primary keyForeign keyReferencesJoins on (not a key)

Drag to pan, scroll or pinch to zoom, click a table to see what it joins to.

Table reference

18 tables · click a table for its columns
orders59 columns · Ordersshow in diagram

Primary key: line_item_id

ColumnTypeKeyDescription
order identity / status
order_idTikTok Shop order id. One order has one row per line item. Redshift DISTKEY.varchar(64)TikTok Shop order id. One order has one row per line item. Redshift DISTKEY.
order_statusvarchar(64)
order_typevarchar(64)
Opaque TikTok buyer id. The ONLY repeat-customer key available: TikTok does not expose buyer email and masks name/phone/address.
buyer_user_idvarchar(64)
create_time_utctimestamp
order_date_ptRedshift SORTKEY.dateRedshift SORTKEY.
update_time_utctimestamp
paid_time_utctimestamp
delivery_time_utctimestamp
cancel_reasonvarchar(512)
is_codsmallint
is_sample_ordersmallint
fulfillment
fulfillment_typevarchar(64)
delivery_option_namevarchar(256)
shipping_providervarchar(256)
payment_method_namevarchar(128)
warehouse_idvarchar(64)
seller_notevarchar(2048)
buyer_messagevarchar(2048)
order-level money: REPEATED on every line of the order. Filter is_order_first_line = 1 before summing these.
currencyvarchar(8)
order_total_amountdecimal(18,4)
order_sub_totaldecimal(18,4)
order_shipping_feedecimal(18,4)
order_seller_discountdecimal(18,4)
order_platform_discountdecimal(18,4)
order_original_total_product_pricedecimal(18,4)
order_original_shipping_feedecimal(18,4)
order_shipping_fee_seller_discountdecimal(18,4)
order_shipping_fee_platform_discountdecimal(18,4)
order_taxdecimal(18,4)
address (district_info L0..L3 flattened)
recipient_namevarchar(256)
recipient_phonevarchar(64)
full_addressvarchar(1024)
postal_codevarchar(32)
region_codevarchar(8)
countryvarchar(128)
statevarchar(128)
countyvarchar(128)
cityvarchar(128)
line item: these ARE safe to sum directly
line_item_idPrimary key.varchar(64)PK Primary key.
product_idvarchar(64)
product_namevarchar(1024)
sku_idvarchar(64)
seller_skuvarchar(256)
sku_namevarchar(512)
sku_typevarchar(64)
line_original_pricedecimal(18,4)
line_sale_pricedecimal(18,4)
line_seller_discountdecimal(18,4)
line_platform_discountdecimal(18,4)
package_idvarchar(64)
package_statusvarchar(64)
line_display_statusvarchar(64)
line_shipping_provider_namevarchar(256)
line_tracking_numbervarchar(128)
grain helpers + housekeeping
order_line_countinteger
is_order_first_line1 on the first line of each order. Filter on it before summing order-level (order_*) amounts.smallint1 on the first line of each order. Filter on it before summing order-level (order_*) amounts.
shop_idvarchar(64)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
shop_performance_daily29 columns · Shop & product analyticsshow in diagram

Primary key: date

ColumnTypeKeyDescription
datePrimary key. Redshift SORTKEY.datePK Primary key. Redshift SORTKEY.
currencyvarchar(8)
gmvdecimal(18,4)
ordersinteger
sku_ordersinteger
units_soldinteger
buyersinteger
avg_order_valuedecimal(18,4)
refundsdecimal(18,4)
cancellations_and_returnsinteger
product_impressionsbigint
product_page_viewsbigint
avg_product_page_visitorsbigint
gmv_livedecimal(18,4)
gmv_videodecimal(18,4)
gmv_product_carddecimal(18,4)
impressions_livebigint
impressions_videobigint
impressions_product_cardbigint
page_views_livebigint
page_views_videobigint
page_views_product_cardbigint
buyers_liveinteger
buyers_videointeger
buyers_product_cardinteger
visitors_livebigint
visitors_videobigint
visitors_product_cardbigint
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
product_performance_daily9 columns · Shop & product analyticsshow in diagram

Primary key: pk

ColumnTypeKeyDescription
pkPrimary key.varchar(32)PK Primary key.
dateRedshift SORTKEY.dateRedshift SORTKEY.
product_idJoins to orders.product_id.varchar(64)FKJoins to orders.product_id.
currencyvarchar(8)
gmvdecimal(18,4)
ordersinteger
units_soldinteger
click_through_ratedecimal(10,6)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
sku_performance_daily9 columns · Shop & product analyticsshow in diagram

Primary key: pk

ColumnTypeKeyDescription
pkPrimary key.varchar(32)PK Primary key.
dateJoins to product_performance_daily.product_id,date. Redshift SORTKEY.dateFKJoins to product_performance_daily.product_id,date. Redshift SORTKEY.
sku_idJoins to orders.sku_id.varchar(64)FKJoins to orders.sku_id.
product_idJoins to product_performance_daily.product_id,date.varchar(64)FKJoins to product_performance_daily.product_id,date.
currencyvarchar(8)
gmvdecimal(18,4)
sku_ordersinteger
units_soldinteger
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
video_performance_daily9 columns · Videos & LIVEshow in diagram

Video & photo overview, daily (202509 shop_videos/overview_performance). Matches Seller Center's "Video & photo" view (photo-inclusive scope).

Primary key: date

ColumnTypeKeyDescription
datePrimary key. Redshift SORTKEY.datePK Primary key. Redshift SORTKEY.
currencyvarchar(8)
gmvdecimal(18,4)
sku_ordersinteger
avg_customersinteger
product_impressionsbigint
product_clicksbigint
click_through_ratedecimal(10,6)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
videos7 columns · Videos & LIVEshow in diagram

Every video ever posted (identity only; the date window on the source endpoint scopes metrics, not membership — so this is complete history). "Video posts per day/week" = COUNT(*) grouped on video_post_time.

Primary key: video_id

ColumnTypeKeyDescription
video_idPrimary key.varchar(64)PK Primary key.
usernamevarchar(256)
titlevarchar(1000)
video_post_timeRedshift SORTKEY.timestampRedshift SORTKEY.
duration_secondsinteger
product_idsvarchar(2000)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
video_performance_by_video14 columns · Videos & LIVEshow in diagram

Sales-active videos only, day x video grain (creator attribution).

Primary key: pk

ColumnTypeKeyDescription
pkPrimary key.varchar(32)PK Primary key.
dateRedshift SORTKEY.dateRedshift SORTKEY.
video_idReferences videos.video_id.varchar(64)FKReferences videos.video_id.
usernamevarchar(256)
video_post_timetimestamp
currencyvarchar(8)
gmvdecimal(18,4)
gpmdecimal(18,4)
sku_ordersinteger
items_soldinteger
avg_customersinteger
viewsbigint
click_through_ratedecimal(10,6)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
live_performance17 columns · Videos & LIVEshow in diagram

One row per LIVE stream session (zero-sale sessions kept — session counts are a metric). Rates stored as fractions (0.0571 = 5.71%).

Primary key: live_id

ColumnTypeKeyDescription
live_idPrimary key.varchar(64)PK Primary key.
usernamevarchar(256)
titlevarchar(500)
start_timeRedshift SORTKEY.timestampRedshift SORTKEY.
end_timetimestamp
currencyvarchar(8)
gmvdecimal(18,4)
gmv_24hdecimal(18,4)
sku_ordersinteger
created_sku_ordersinteger
items_soldinteger
customersinteger
avg_pricedecimal(18,4)
click_to_order_ratedecimal(10,6)
products_addedinteger
different_products_soldinteger
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
live_product_performance21 columns · Videos & LIVEshow in diagram

Per-LIVE product breakdown (202512). Only the shop's OWN official/ marketing account lives have rows — affiliate creator lives return no data from TikTok. Join live_id to live_performance for session context.

Primary key: pk

ColumnTypeKeyDescription
pkPrimary key.varchar(32)PK Primary key.
live_idReferences live_performance.live_id. Redshift SORTKEY.varchar(64)FKReferences live_performance.live_id. Redshift SORTKEY.
product_idvarchar(64)
product_namevarchar(1000)
currencyvarchar(8)
direct_gmvdecimal(18,4)
avg_pricedecimal(18,4)
sku_ordersinteger
created_sku_ordersinteger
main_ordersinteger
customersinteger
items_soldinteger
payment_ratedecimal(10,6)
add_to_cart_countinteger
product_impressionsbigint
product_clicksbigint
ctrdecimal(10,6)
main_order_ctordecimal(10,6)
sku_order_ctordecimal(10,6)
watch_gpmdecimal(18,4)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
bestselling_products10 columns · Bestsellers (platform-wide)show in diagram

Primary key: pk

ColumnTypeKeyDescription
pkPrimary key.varchar(32)PK Primary key.
dateRedshift SORTKEY.dateRedshift SORTKEY.
time_slotvarchar(4)
rankinteger
product_idvarchar(64)
product_namevarchar(1000)
currencyvarchar(8)
gmv_lowdecimal(18,4)
gmv_highdecimal(18,4)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
bestselling_creators13 columns · Bestsellers (platform-wide)show in diagram

Primary key: pk

ColumnTypeKeyDescription
pkPrimary key.varchar(32)PK Primary key.
dateRedshift SORTKEY.dateRedshift SORTKEY.
time_slotvarchar(4)
rankinteger
usernamevarchar(256)
nick_namevarchar(256)
open_idvarchar(128)
followers_countbigint
likes_countbigint
currencyvarchar(8)
gmv_lowdecimal(18,4)
gmv_highdecimal(18,4)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
bestselling_videos16 columns · Bestsellers (platform-wide)show in diagram

Primary key: pk

ColumnTypeKeyDescription
pkPrimary key.varchar(32)PK Primary key.
dateRedshift SORTKEY.dateRedshift SORTKEY.
time_slotvarchar(4)
rankinteger
video_idvarchar(64)
nick_namevarchar(256)
duration_secondsinteger
likesbigint
commentsbigint
publish_timetimestamp
top_product_idvarchar(64)
top_product_namevarchar(500)
currencyvarchar(8)
gmv_lowdecimal(18,4)
gmv_highdecimal(18,4)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
bestselling_lives15 columns · Bestsellers (platform-wide)show in diagram

Primary key: pk

ColumnTypeKeyDescription
pkPrimary key.varchar(32)PK Primary key.
dateRedshift SORTKEY.dateRedshift SORTKEY.
time_slotvarchar(4)
rankinteger
live_idvarchar(64)
creator_namevarchar(256)
creator_nick_namevarchar(256)
open_idvarchar(128)
titlevarchar(500)
start_timetimestamp
duration_secondsinteger
currencyvarchar(8)
gmv_lowdecimal(18,4)
gmv_highdecimal(18,4)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
finance_statements15 columns · Financeshow in diagram

One row per statement (a shop can get 2+ per day: orders + adjustments). Upsert key statement_id; re-pulled over a trailing window so payment status/payment_id updates land.

Primary key: statement_id

ColumnTypeKeyDescription
statement_idPrimary key.varchar(64)PK Primary key.
statement_time_utctimestamp
statement_dateRedshift SORTKEY.dateRedshift SORTKEY.
currencyvarchar(8)
settlement_amountdecimal(18,4)
revenue_amountdecimal(18,4)
net_sales_amountdecimal(18,4)
fee_amountdecimal(18,4)
shipping_cost_amountdecimal(18,4)
adjustment_amountdecimal(18,4)
payment_statusvarchar(32)
payment_idReferences finance_payments.payment_id.varchar(64)FKReferences finance_payments.payment_id.
payment_time_utctimestamp
shop_idvarchar(64)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
finance_statement_transactions87 columns · Financeshow in diagram

One row per transaction in a statement: an ORDER settlement, an adjustment (type = the adjustment policy, e.g. CHARGE_BACK) or a RESERVE movement. Upsert key pk = md5(statement_id|transaction_id). Breakdown groups each sum to their parent amount: revenue_amount = gross_sales .. other_revenue_amount shipping_cost_amount = actual_shipping_fee .. other_shipping_amount fee_tax_amount = platform_commission .. other_tax_amount The "supplementary" columns are informational (TikTok reports them but they do not add into the settlement). breakdown_json keeps every non-zero breakdown value as returned, so new TikTok fee lines are never lost.

Primary key: pk

ColumnTypeKeyDescription
pkPrimary key.varchar(32)PK Primary key.
statement_idReferences finance_statements.statement_id.varchar(64)FKReferences finance_statements.statement_id.
statement_time_utctimestamp
statement_dateRedshift SORTKEY.dateRedshift SORTKEY.
transaction_idvarchar(64)
transaction_typevarchar(64)
order_idJoins to orders.order_id. Redshift DISTKEY.varchar(64)FKJoins to orders.order_id. Redshift DISTKEY.
order_create_time_utctimestamp
adjustment_idvarchar(64)
adjustment_order_idvarchar(64)
reserve_idvarchar(64)
reserve_statusvarchar(32)
associated_order_idvarchar(64)
estimated_release_time_utctimestamp
currencyvarchar(8)
totals
settlement_amountdecimal(18,4)
revenue_amountdecimal(18,4)
shipping_cost_amountdecimal(18,4)
fee_tax_amountdecimal(18,4)
adjustment_amountdecimal(18,4)
reserve_amountdecimal(18,4)
revenue breakdown (sums to revenue_amount)
gross_sales_amountdecimal(18,4)
gross_sales_refund_amountdecimal(18,4)
seller_discount_amountdecimal(18,4)
seller_discount_refund_amountdecimal(18,4)
other_revenue_amountdecimal(18,4)
shipping breakdown (sums to shipping_cost_amount)
actual_shipping_fee_amountdecimal(18,4)
shipping_fee_discount_amountdecimal(18,4)
customer_paid_shipping_fee_amountdecimal(18,4)
return_shipping_fee_amountdecimal(18,4)
fbt_free_shipping_fee_amountdecimal(18,4)
fbt_fulfillment_fee_reimbursement_amountdecimal(18,4)
shipping_insurance_fee_amountdecimal(18,4)
signature_confirmation_fee_amountdecimal(18,4)
logistics_service_fee_amountdecimal(18,4)
other_shipping_amountdecimal(18,4)
shipping, informational (not addends): the TikTok Shop shipping incentive is part of shipping_fee_discount_amount
tts_shipping_incentive_amountdecimal(18,4)
fbt_fulfillment_fee_amountdecimal(18,4)
fbt_shipping_cost_amountdecimal(18,4)
fbm_shipping_cost_amountdecimal(18,4)
platform_shipping_fee_discount_amountdecimal(18,4)
seller_shipping_fee_discount_amountdecimal(18,4)
customer_shipping_fee_offset_amountdecimal(18,4)
fees + taxes (sum to fee_tax_amount)
platform_commission_amountdecimal(18,4)
referral_fee_amountdecimal(18,4)
refund_administration_fee_amountdecimal(18,4)
transaction_fee_amountdecimal(18,4)
credit_card_handling_fee_amountdecimal(18,4)
affiliate_commission_amountdecimal(18,4)
affiliate_partner_commission_amountdecimal(18,4)
affiliate_ads_commission_amountdecimal(18,4)
affiliate_commission_deposit_amountdecimal(18,4)
affiliate_commission_release_amountdecimal(18,4)
cofunded_creator_bonus_amountdecimal(18,4)
tap_shop_ads_commission_amountdecimal(18,4)
external_affiliate_marketing_fee_amountdecimal(18,4)
gmv_max_ad_fee_amountdecimal(18,4)
gmv_max_coupon_fee_amountdecimal(18,4)
smart_promotion_fee_amountdecimal(18,4)
campaign_period_fee_amountdecimal(18,4)
flash_sales_service_fee_amountdecimal(18,4)
sfp_service_fee_amountdecimal(18,4)
live_specials_fee_amountdecimal(18,4)
bonus_cashback_service_fee_amountdecimal(18,4)
voucher_xtra_service_fee_amountdecimal(18,4)
cofunded_promotion_service_fee_amountdecimal(18,4)
seller_growth_fee_amountdecimal(18,4)
epr_pob_service_fee_amountdecimal(18,4)
other_fee_amountdecimal(18,4)
sales_tax_on_fees_amountdecimal(18,4)
vat_amountdecimal(18,4)
import_vat_amountdecimal(18,4)
customs_duty_amountdecimal(18,4)
other_tax_amountdecimal(18,4)
supplementary (informational)
customer_payment_amountdecimal(18,4)
customer_refund_amountdecimal(18,4)
platform_discount_amountdecimal(18,4)
platform_discount_refund_amountdecimal(18,4)
seller_cofunded_discount_amountdecimal(18,4)
seller_cofunded_discount_refund_amountdecimal(18,4)
platform_cofunded_discount_amountdecimal(18,4)
platform_cofunded_discount_refund_amountdecimal(18,4)
sales_tax_amountdecimal(18,4)
retail_delivery_fee_amountdecimal(18,4)
breakdown_jsonvarchar(8000)
shop_idvarchar(64)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
finance_payments14 columns · Financeshow in diagram

Payouts to the seller's bank account. Upsert key payment_id.

Primary key: payment_id

ColumnTypeKeyDescription
payment_idPrimary key.varchar(64)PK Primary key.
create_time_utcRedshift SORTKEY.timestampRedshift SORTKEY.
paid_time_utctimestamp
statusvarchar(32)
amountdecimal(18,4)
currencyvarchar(8)
settlement_amountdecimal(18,4)
settlement_currencyvarchar(8)
amount_before_exchangedecimal(18,4)
currency_before_exchangevarchar(8)
exchange_ratedecimal(18,6)
bank_account_last4varchar(4)
shop_idvarchar(64)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
finance_withdrawals8 columns · Financeshow in diagram

Seller balance movements: SETTLE (statement credited), WITHDRAW (payout), TRANSFER (platform subsidy/deduction), REVERSE (failed payout). Upsert key withdrawal_id.

Primary key: withdrawal_id

ColumnTypeKeyDescription
withdrawal_idPrimary key.varchar(64)PK Primary key.
withdrawal_typevarchar(32)
statusvarchar(32)
amountdecimal(18,4)
currencyvarchar(8)
create_time_utcRedshift SORTKEY.timestampRedshift SORTKEY.
shop_idvarchar(64)
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.
finance_unsettled_transactions32 columns · Financeshow in diagram

SNAPSHOT of transactions not yet settled (orders created since 2025-01-01), with TikTok's ESTIMATED amounts. Each run replaces the shop's rows (upsert key shop_id); once a transaction settles it leaves this table and appears in finance_statement_transactions with final amounts.

Primary key: shop_id, order_id

ColumnTypeKeyDescription
transaction_idvarchar(64)
transaction_typevarchar(64)
statusvarchar(32)
order_idPrimary key (with shop_id). Joins to orders.order_id.varchar(64)PK FKPrimary key (with shop_id). Joins to orders.order_id.
adjustment_idvarchar(64)
adjustment_order_idvarchar(64)
order_create_time_utcRedshift SORTKEY.timestampRedshift SORTKEY.
order_delivery_time_utctimestamp
estimated_settlement_time_utctimestamp
estimated_settlement_notevarchar(256)
unsettled_reasonvarchar(512)
currencyvarchar(8)
est_settlement_amountdecimal(18,4)
est_revenue_amountdecimal(18,4)
est_shipping_cost_amountdecimal(18,4)
est_fee_tax_amountdecimal(18,4)
est_adjustment_amountdecimal(18,4)
gross_sales_amountdecimal(18,4)
gross_sales_refund_amountdecimal(18,4)
seller_discount_amountdecimal(18,4)
seller_discount_refund_amountdecimal(18,4)
actual_shipping_fee_amountdecimal(18,4)
shipping_fee_discount_amountdecimal(18,4)
customer_paid_shipping_fee_amountdecimal(18,4)
platform_commission_amountdecimal(18,4)
referral_fee_amountdecimal(18,4)
affiliate_commission_amountdecimal(18,4)
affiliate_partner_commission_amountdecimal(18,4)
affiliate_ads_commission_amountdecimal(18,4)
breakdown_jsonvarchar(8000)
shop_idPrimary key (with order_id).varchar(64)PK Primary key (with order_id).
_synced_atWhen jsdata last wrote this row.timestampWhen jsdata last wrote this row.

Connect TikTok Shop All connectors