How to get your Facebook Marketing data ready for agentic AI
Sync Facebook Marketing campaigns, ads, and Ads Insights with Airbyte so AI agents can analyze spend and performance from a governed copy.

Airbyte replicates Facebook Marketing objects and Ads Insights into your warehouse, and the Airbyte context layer lets agents read campaigns, ads, and insights directly through the Airbyte MCP.
Paid social is one of the first places teams want an AI agent to help. The questions are repetitive and data-heavy: which ad sets lost efficiency this week, which creatives are fatiguing, how spend compares with last month. The Facebook Marketing API can answer them, but it is a poor thing to point an agent at directly. It paginates, it throttles, its attribution windows shift numbers after the fact, and its insights are only available for a limited history.
A better pattern is to keep a governed copy of your Facebook Marketing data in a warehouse, and let agents query that copy. For lookups where the latest state matters more than history, Airbyte also offers read-only direct access through its context layer.
Why Facebook Marketing data matters for agentic AI
Facebook Marketing data is structured in a way agents can use well, once it is in one place:
- A clear hierarchy. Ad accounts contain campaigns, campaigns contain ad sets, ad sets contain ads, and ads reference creatives. That hierarchy lets an agent move from a top-line number down to the specific ad responsible for it.
- Rich performance metrics. Ads Insights carry spend, impressions, clicks, and actions, broken down by age, gender, country, platform, device, and more.
- Cross-channel context. Joined with Google Ads, TikTok, and your CRM or billing data, it lets an agent answer questions about blended spend and pipeline instead of one channel at a time.
What agents can do with Facebook Marketing data
- Explain performance changes. Compare Ads Insights by day and breakdown to find which ad sets or placements moved a metric, then point to the ads involved.
- Monitor creative fatigue. Track frequency and click-through trends by ad and creative, and flag ads whose efficiency has dropped over a chosen window.
- Summarize account activity. The connector includes an activities stream for the ad account, which an agent can scan alongside insights to see what happened in the account before a performance shift.
- Report blended spend. Combine Facebook spend with other channels in the warehouse and attribute it against conversions or revenue you track elsewhere.
- Answer quick status questions. With agent access turned on, an agent can list active campaigns or look up an ad's details directly, without waiting for the next sync.
How Airbyte gets Facebook Marketing data ready
Authentication
On Airbyte Cloud you authenticate with Facebook through OAuth. On self-managed Airbyte, the recommended option is a system user access token with the ads_read, ads_management, and business_management permissions. Your app needs the appropriate Marketing API access tier to avoid strict rate limits.
Streams
The connector syncs the core objects:
ad_account,campaigns,ad_sets,adsad_creativesandad_creatives_from_adsads_insightsactivitiescustom_conversions,custom_audiencesimages,videos
It also ships prebuilt Ads Insights breakdown streams, for example by age and gender, country, region, platform and device, and action type. When those do not fit, you can define custom insights by choosing the level (account, campaign, ad set, or ad), fields, breakdowns, action breakdowns, and time increment.
Sync behavior and limits
- Incremental syncs are supported for most streams. Ad creatives, the ad account, custom conversions, and custom audiences are full refresh only.
- Insights history is limited to 37 months by the Marketing API.
- Lookback window. Insights are re-read over a lookback window, 28 days by default, so conversions attributed after the fact update your copy.
- Attribution windows. You can set click-through attribution up to 28 days and view-through attribution of one day. Meta removed the longer view-through windows in January 2026, and the connector reflects that.
- Archived and deleted objects are excluded unless you add those statuses to the connector's status filters.
- Large requests. If Facebook returns "Please reduce the amount of data you're asking for," the connector docs cover the fixes, including switching from
ad_creativesto thead_creatives_from_adsstream, which fetches creative data through the Ads endpoint instead. - Custom insights level. The level defaults to ad and determines the primary key used for deduplication.
Destinations
Choose a destination that fits how agents will query. Snowflake and BigQuery support context layer SQL access. Incremental Append + Deduped keeps one current row per object for entity streams, while insights streams keep one row per date and breakdown key.
How agents reach Facebook Marketing data
Facebook Marketing is an agent connector, so it works with both parts of the Airbyte context layer in Airbyte Cloud:
- Agent access (direct reads). Agents can list and get ad accounts, campaigns, ad sets, ads, ad creatives, Ads Insights, custom conversions, images, videos, and pixels. Direct reads use the credentials saved in Airbyte, need no connection or sync, and are read-only. They count toward Facebook's API rate limits.
- Search. When a connection syncs Facebook Marketing to an agent-connector destination, Airbyte can index the synced streams for keyword, semantic, or hybrid search. Only the streams selected in the connection are indexed. The open-source Airbyte agent SDK lists semantic search for ad creatives.
Agents use these features through the Airbyte MCP at https://mcp.airbyte.com/mcp, which signs in with OAuth and acts with your Airbyte permissions. The context layer is free for up to 100,000 direct reads and searches combined per organization per month. It is available only in Airbyte Cloud.
What this unlocks
- Paid social analysis from a stable warehouse copy instead of live API pagination.
- Insights that stay correct as late conversions arrive, through the lookback window.
- Drill-down from account totals to individual ads and creatives.
- Read-only direct lookups for "what is running right now" questions.
- Blended reporting with other ad platforms and revenue data.
Getting started
- Create a Facebook Marketing source in Airbyte Cloud and authenticate with OAuth.
- Pick the insights breakdowns your team reports on, and add a custom insights stream if needed.
- Connect it to BigQuery or Snowflake with incremental syncs.
- Turn on agent access and connect your agent to the Airbyte MCP.
Try Airbyte free or talk to sales about marketing data for agents.
Frequently asked questions
How far back can Airbyte sync Facebook Ads Insights?
Ads Insights are limited to the last 37 months by the Facebook Marketing API, so the connector cannot sync insights older than that. Sync history early and keep it in your destination if you need longer trends.
Why do recent Facebook metrics change after a sync?
Conversions can be attributed after the ad was shown. The connector re-reads recent insights within an insights lookback window, 28 days by default, so later attributions update the synced rows.
Does the connector sync archived or deleted ads?
Not by default. Archived and deleted campaigns, ad sets, and ads are excluded unless you include those statuses in the connector's status filters.
Can I sync custom Ads Insights breakdowns?
Yes. Besides the prebuilt breakdown streams, you can define custom insights streams by choosing the level, fields, breakdowns, action breakdowns, and time increment.
Can an agent change my Facebook campaigns through the Airbyte MCP?
No. Direct reads and searches through the context layer are read-only. An agent can retrieve campaigns, ads, and insights, but it cannot create, update, or delete them through these tools.
Integrate with 700+ apps using Airbyte
Move data from 700+ sources into warehouses, lakes, and beyond. Set up pipelines in minutes with pre-built connectors and the Connector Builder.
