Integration Specifications

Integration Overview

Facebook is the largest social media platform globally, meaning it is the destination allowing advertisers to reach the largest majority of potential consumers.

The Daasity Facebook Ads integration extracts key advertising information from the Facebook Ads platform, which includes Instagram advertising as well. Data such as spend, clicks and impressions are extracted on a daily basis and populate your data warehouse.

Only 37 months of history available

Facebook exposes only the last 37 months of history in their API. We will not be able to extract data for any activity outside of that window. (source)

Integration Availability

This integration is available for:

  • Enterprise

  • Growth

API Endpoints

The Daasity Facebook Ads extractor is built based on this Facebook Ads Marketing Insights API Documentation. The following endpoints are used by Daasity to replicate data from Facebook Ads.

Entity Relationship Diagram (ERD)

Click here to view the ERD for the Daasity Facebook Ads integration illustrating the different tables and keys to join across tables.

Facebook Ads Schema

The Daasity Facebook Ads extractor creates these tables using the endpoints and replication methods listed. The data is mapped from the source API endpoint to the table based on the mapping logic outlined in each table.

Ads

  • Endpoint: Ads

  • Update Method: UPSERT

  • Table Name: [facebook_marketing.ads]

JSON Element  Database Column 

id

id

Date queried in API

date

name

ad_name

status

ad_status

Facebook Account ID

ad_account_id

ID of Merchant in Daasity App

_account_id

timestamp when data was extracted from Shopify

__synced_at

Ad Sets

  • Endpoint: Ad Sets

  • Update Method: UPSERT

  • Table Name: [facebook_marketing.adsets]

JSON Element  Database Column 

id

id

Date queried in API

date

name

adset_name

status

adset_status

targeting::geo_locations::countries

target_country

targeting::publisher_platforms

target_platform

Facebook Account ID

ad_account_id

ID of Merchant in Daasity App

_account_id

timestamp when data was extracted from Shopify

__synced_at

Ad Spends

  • Endpoint: Insights

  • Update Method: UPSERT

  • Table Name: [facebook_marketing.ad_spends]

JSON ElementDatabase Column 

id

id

Date queried in API

date

campaign_id

campaign_id

adset_id

adset_id

ad_id

ad_id

account_name

account_name

spend

spend

cpc

cpc

cpm

cpm

cpp

cpp

ctr

ctr

account_currency

account_currency

date_start

date

date_stop

date_stop

attribution_setting

attribution_setting

buying_type

buying_type

conversion_rate_ranking

conversion_rate_ranking

engagement_rate_ranking

engagement_rate_ranking

objective

objective

optimization_goal

optimization_goal

quality_ranking

quality_ranking

canvas_avg_view_percent

canvas_avg_view_percent

canvas_avg_view_time

canvas_avg_view_time

cost_per_estimated_ad_recallers

cost_per_estimated_ad_recallers

cost_per_inline_link_click

cost_per_inline_link_click

cost_per_inline_post_engagement

cost_per_inline_post_engagement

cost_per_unique_click

cost_per_unique_click

cost_per_unique_inline_link_click

cost_per_unique_inline_link_click

reach

reach

social_spend

social_spend

qualifying_question_qualify_answer_rate

qualifying_question_qualify_answer_rate

estimated_ad_recall_rate

estimated_ad_recall_rate

estimated_ad_recallers

estimated_ad_recallers

frequency

frequency

full_view_impressions

full_view_impressions

full_view_reach

full_view_reach

impressions

impressions

clicks

clicks

inline_link_click_ctr

inline_link_click_ctr

inline_link_clicks

inline_link_clicks

inline_post_engagement

inline_post_engagement

instant_experience_clicks_to_open

instant_experience_clicks_to_open

instant_experience_clicks_to_start

instant_experience_clicks_to_start

app_custom_event.fb_mobile_purchase

mobile_purchase_count

onsite_conversion.purchase

onsite_purchase_count

app_custom_event.fb_mobile_purchase

mobile_purchase_value

onsite_conversion.purchase

onsite_purchase_value

purchase_value::adspend

purchase_value

purchase_count::adspend

purchase_count

attribution_window["xd_click", "xd_view"]

attribution_window

Facebook Account ID

ad_account_id

ID of Merchant in Daasity App

_account_id

timestamp when data was extracted from Shopify

__synced_at

Campaigns

  • Endpoint: Campaigns

  • Update Method: UPSERT

  • Table Name: [facebook_marketing.campaigns]

JSON Element  Database Column 

id

id

Date queried in API

date

id

campaign_id

name

campaign_name

status

campaign_status

Facebook Account ID

ad_account_id

ID of Merchant in Daasity App

_account_id

timestamp when data was extracted from Shopify

__synced_at

Last updated