Try Kling Image V4 Long for Page Mockups from Kling AI →
Models
Agents
Workflows
Studio
PricingBlogDocs
ExploreDiscover models by categoryDiscoverModels and effects built by WiroBrowse All ModelsBrowse the complete catalogSee FavoritesSign in to view saved models
Generative Media AgentCreate and edit media by chattingWorkflow AgentBuild visual workflows with Agent
OverviewThe platform at a glanceLearnSkills, knowledge, guardrailsAnatomyWhat makes agents reasonBuild Your AgentPick skills, choose a plan, deploy, then connect your tools
Pre-built AgentsBrowse the catalogConnectorsConnect agents to your apps
Agent Usecases
Ad Campaign ManagerApp Event ManagerApp Review RepliesBarber BookingCustomer Win-BackEcommerce ListingsRestaurant Reviews
Sign InStart Building
  1. Home
  2. Connectors
  3. Ads
  4. Meta Ads
Wiro × Meta Ads
Meta Ads logo

Connect Meta Ads to your Wiro AI agent

Campaigns, ad sets, ads, audiences and insights on Facebook and Instagram ads.

Connect to an AgentVisit Meta Ads All Connectors
Example chat
Meta Ads logoMeta Ads connected Signed in

Break down last month's Meta spend for Lanternfield Candles by age and placement, and point out what didn't bring purchases.

List Meta ad accounts meta-ads__list_ad_accounts
Get Meta Ads insights meta-ads__get_insights

Last month the account spent $6,420 for 214 purchases, about $30 each. Three slices took money with little back:

  • Audience Network: $780 for 2 purchases
  • Instagram Reels: $1,040 for 9 purchases, $116 each
  • Ages 18 to 24: $1,350 for 11 purchases, $123 each

Ages 35 to 54 bought at $21 a purchase. Should I draft placement and age changes for you to approve?

Type a message...
Sign In or KeyWith your own Meta Ads app, or with an API key
21 actions11 read, 10 write
Chat and Scheduled TasksWhere it works
Allow, Ask or BlockYour choice for each action

Overview

What Meta Ads does for your agent

Takes a system user token from Meta Business Settings, or a Facebook sign-in through your own Meta app, and works only on the ad accounts and Pages you pick. The agent reads insights broken down by age, gender, country, placement and device, sizes audiences, uploads images and videos, builds creatives, creates campaigns, ad sets and ads, turns them on or off, changes budgets and deletes them. Campaigns, ad sets and ads it creates start paused, and Meta reviews each ad before it runs.

Use cases

What your Wiro agent can do with Meta Ads

A Monday report on spend, results and ROAS for every campaign

Each Monday morning, a Scheduled Task collects last week's spend, results, cost per result and ROAS for each campaign in your chosen ad accounts and puts them beside the previous week. Campaigns whose cost per result went up are listed first, and the whole table goes to Chat.

The ages, countries and placements that use budget without results

Ask the agent to break last month's results down by age, gender, country, placement or device. It shows where spend went without results and which segments convert for less, then drafts the targeting or placement changes for you to approve.

A new campaign from a brief and a few creatives, created paused

Share the offer, budget, audience and links to your images or video. The agent uploads the media, writes the primary text and headline, builds an image, video or carousel creative for your Page, and creates the campaign, ad set and ads paused. They stay off until you ask the agent to turn them on, and Meta reviews each ad before it runs.

A morning budget and ad fatigue check with changes you approve

Each morning, the agent compares every active ad set's cost per result with your target and looks for ads whose frequency climbs while their click-through rate falls. It lists the budget raises and pauses it recommends; reply in Chat with the ones you want and it applies them, showing each value before and after.

Audience sizing before you spend on a new ad set

Describe your customer and ask for matching interests, job titles, employers or locations. The agent finds Meta's targeting options with their size ranges and estimates how many people a combined spec reaches, so you can compare a few audiences before an ad set is created.

A daily watch on account status and spend caps

A daily Scheduled Task checks each chosen ad account's status, amount spent, balance and spend cap. It warns in Chat when an account is disabled, with the reason Meta gives, or when spend gets close to the cap, so a stop in delivery does not go unnoticed.

How it works

How Meta Ads works with Wiro

  1. 01

    Connect Meta Ads

    Deploy an agent, open its Connectors tab, choose Meta Ads and sign in with your Meta Ads account, or paste an API key.

  2. 02

    Choose what each action may do

    Set each Meta Ads action to Allow, Ask or Block, in Chat and in Scheduled Tasks. By default, read-only actions run, and the rest ask first in Chat.

  3. 03

    Ask in Chat or schedule it

    Ask your agent for Meta Ads work in Chat, or put it on a Scheduled Task that runs on its own.

  • Where it runsInside your agent. Its requests go straight from the agent to Meta Ads.
  • Where its data goesgraph.facebook.com
  • How it signs inSign in to Meta Ads with your own app, or connect with a key.
  • AccountsAfter connecting, pick the Meta ad accounts, Facebook Pages for ads the agent may work with. It cannot reach any other.

What it can do

Actions your Wiro agent can take in Meta Ads

By default, read-only actions run, and the rest ask first in Chat and run in Scheduled Tasks. Each agent can set any action to Allow, Ask or Block.

Read-only (11)Create and send (6)Change and delete (4)

Read-only 11 actions

Looks things up in Meta Ads and changes nothing.

ActionWhat it doesChatScheduled Tasks
List Meta ad accountsLists the ad accounts this connection can use, with id, name, status, currency, time zone and the connected account's tasks.AllowAllow
Get a Meta ad accountReturns an ad account's status (and why it is disabled), the connected account's tasks on it, currency, time zone, amount spent, balance, spend cap and minimum daily budget (money in the currency's minor unit).AllowAllow
List Facebook Pages for adsLists the Facebook Pages this connection can use in ad creatives.AllowAllow
Get Meta Ads insightsReads ad performance for an ad account at account, campaign, ad set or ad level: spend, impressions, reach, clicks, CTR, CPC, CPM, frequency, actions, cost per action and ROAS by default.AllowAllow
List Meta campaigns, ad sets, ads or creativesLists an ad account's campaigns, ad sets, ads or creatives, newest first, with status, effective status and, for campaigns and ad sets, budgets, bid strategy and schedule.AllowAllow
Get a Meta campaign, ad set, ad or creativeReturns one campaign, ad set, ad or creative with its ad account, status, effective status and settings (budgets in minor units, targeting, creative).AllowAllow
List Meta custom audiencesLists an ad account's custom and lookalike audiences with their size range, source, delivery status and last update.AllowAllow
List Meta ad images or videosLists an ad account's uploaded ad images (hash, name, URL, size) or ad videos (id, title, processing status, length).AllowAllow
Search Meta targeting optionsFinds targeting ids for an ad set: interests, places, languages (adlocale), employers, job titles, schools and fields of study, with the audience size range Meta gives.AllowAllow
Estimate a Meta Ads audienceEstimates how many people a targeting spec reaches in an ad account (the monthly active range Meta gives), for an optimization goal.AllowAllow
Read other Meta Ads dataReads what the actions above do not cover, straight from the Meta Ads API.AllowAllow

Create and send 6 actions

Creates or sends something new in Meta Ads, such as a post, a message or an email.

ActionWhat it doesChatScheduled Tasks
Create a Meta Ads campaign (paused)Creates a campaign in an ad account, always paused, with an objective, special ad categories, and optionally a campaign budget (daily or lifetime, in minor units) and bid strategy.AskAllow
Create a Meta ad set (paused)Creates an ad set in a campaign, always paused: targeting, optimization goal, billing event, and, unless the campaign has its own budget, a daily or lifetime budget in minor units.AskAllow
Upload a Meta ad imageDownloads an image from a public https URL (JPEG, PNG or GIF, up to 30 MB) and uploads it to an ad account's image library.AskAllow
Upload a Meta ad videoAdds a video to an ad account from a public https URL (Meta downloads it; MP4 or MOV).AskAllow
Create a Meta ad creativeCreates an ad creative for one of the chosen Facebook Pages (and optionally an Instagram account): an image ad, a video ad or a carousel of 2 to 10 cards, with primary text, headline (40) and description (30).AskAllow
Create a Meta ad (paused)Creates an ad in an ad set from a creative, always paused.AskAllow

Change and delete 4 actions

Changes or deletes what is already in Meta Ads.

ActionWhat it doesChatScheduled Tasks
Turn a Meta campaign, ad set or ad on or offSets a campaign, ad set or ad to ACTIVE (it can start spending), PAUSED or ARCHIVED, after checking it belongs to a chosen ad account.AskAllow
Change a Meta campaign or ad set budgetChanges the budget of a campaign or ad set after checking it belongs to a chosen ad account: daily or lifetime budget, bid amount, spend cap (campaigns) or end time (ad sets).AskAllow
Delete a Meta campaign, ad set or adDeletes a campaign, ad set or ad after checking it belongs to a chosen ad account.AskAllow
Make other Meta Ads changesSends any other change straight to the Meta Ads API.AskAllow

How to connect

Connect Meta Ads to Wiro

Open the agent's Connectors tab, choose Meta Ads and sign in with your account. The consent screen shows what the agent can reach.

What the Connect dialog asks for

Pick one way in the Connect dialog: it asks only for what that way needs.

Your own app

App ID and App Secret from your own Meta Ads app, then you sign in to Meta Ads in its own window.

FieldAbout
App IDRequired
  1. Go to Meta for Developers
  2. Select your app (or create one and choose Business type)
  3. Go to Settings → Basic
  4. Copy the App ID
  5. Under App Review → Permissions, enable ads_management, ads_read, and business_management. For Page discovery and Page-backed creatives, also enable pages_show_list, pages_manage_ads, and pages_read_engagement
  6. Under Facebook Login → Settings, add this Valid OAuth Redirect URI:

https://api.wiro.ai/v1/AgentConnector/OAuthCallback

Used only to sign in; the agent never receives it.
App SecretRequired
  1. Go to Meta for Developers → your app
  2. Go to Settings → Basic
  3. Click Show next to App Secret and copy it
Used only to sign in; the agent never receives it.

API key

The key, pasted once instead of a sign-in.

FieldAbout
System User TokenRequired

Use a token generated for a Business Manager System User, not a personal Facebook login token.

  1. Open Meta Business Settings → Users → System Users
  2. Create or select a System User and assign the required ad account assets with ADVERTISE and ANALYZE tasks. For Page-backed creatives, also assign each relevant Facebook Page with its advertising task
  3. Choose Generate new token and select the Business app used for the integration
  4. At Set expiration, choose Never when Meta offers it. Some businesses are required to use Meta's expiring token option; those tokens must be regenerated and reconnected before they expire
  5. Grant ads_management, ads_read, and business_management. Add pages_show_list, pages_read_engagement, and pages_manage_ads when this agent will create Page-backed ad creatives
  6. Generate and copy the token; Meta does not show it again. It is stored and used unchanged

No App ID or App Secret is required for this direct connection. The Meta app used to generate the token must not enforce appsecret_proof on every server call. If a permission is missing from the token dialog, review Meta's use-case permission mapping and add the matching app use case.

Kept encrypted, never shown again.

Troubleshooting

Troubleshooting Meta Ads

What to check when Meta Ads stops working for your agent.

  • Your own app's sign-in fails Check your app's settings in Meta Ads: the redirect URL shown in the Connect dialog must be added there, and the client secret you pasted must be the app's current one. Then sign in again.
  • Access revoked in Meta Ads If the access is removed in Meta Ads, or the sign-in can no longer renew, the connection reads Reconnect needed. Open the agent's Connectors tab, choose Meta Ads and Reconnect.
  • An invalid or expired key If Meta Ads refuses the key, for example after it was deleted or expired, the agent's Meta Ads actions fail. Create a new key in Meta Ads, then open the agent's Connectors tab, choose Meta Ads and paste it in place of the old one.
  • Limits set by Meta Ads Meta Ads limits how much an account can do, such as how many requests it takes in a minute. An action over a limit fails until the limit resets: wait and ask again, or check your Meta Ads plan.

For developers

Connect Meta Ads from your own product

Every call is a POST to the Wiro API with your project's API key. On a sign-in, your customers see your own app's name.

  1. 01

    Read the connector

    Detail answers without a session: what the connector needs and the tools it gives an agent.

    POST /AgentConnector/Detail
    {
      "slug": "meta-ads"
    }
    Response
    {
      "result": true,
      "errors": [],
      "agentconnectors": [
        {
          "slug": "meta-ads",
          "title": "Meta Ads",
          "category": "ads",
          "authtype": "provider-oauth",
          "credentialfields": [
            {
              "name": "appid",
              "label": "App ID",
              "required": true,
              "secret": false,
              "format": "text"
            },
            {
              "name": "appsecret",
              "label": "App Secret",
              "required": true,
              "secret": true,
              "format": "password"
            },
            {
              "name": "systemusertoken",
              "label": "System User Token",
              "required": true,
              "secret": true,
              "format": "password"
            }
          ],
          "accountpickers": [
            {
              "key": "ad_accounts",
              "label": "Meta ad accounts",
              "multiple": true
            },
            {
              "key": "pages",
              "label": "Facebook Pages for ads",
              "multiple": true
            }
          ],
          "tools": [
            {
              "name": "list_ad_accounts",
              "readonly": true
            },
            {
              "name": "get_ad_account",
              "readonly": true
            }
          ]
        }
      ]
    }
  2. 02

    Start the sign-in

    Connect answers with the vendor's sign-in page. Open it in the browser of the person who owns the account.

    POST /UserAgent/ConnectorConnect
    {
      "useragentguid": "YOUR_AGENT_GUID",
      "slug": "meta-ads",
      "mode": "oauth",
      "values": {
        "appid": "YOUR_APPID",
        "appsecret": "YOUR_SECRET"
      },
      "redirecturl": "https://your-app.example.com/connectors/return"
    }
    Response
    {
      "result": true,
      "errors": [],
      "status": "pending",
      "authorizeUrl": "https://vendor.example.com/oauth/authorize?client_id=...&state=..."
    }
  3. 03

    Come back to your page

    After the consent screen the browser returns to your redirect URL with the outcome in its query. Read the status next; the query is only a reason to look.

    Your redirect URL
    https://your-app.example.com/connectors/return?connector_connected=true
    https://your-app.example.com/connectors/return?connector_error=authorization_denied
  4. 04

    Or connect with a key

    The same call with mode "key" connects with a pasted key instead of a sign-in.

    POST /UserAgent/ConnectorConnect
    {
      "useragentguid": "YOUR_AGENT_GUID",
      "slug": "meta-ads",
      "mode": "key",
      "values": {
        "systemusertoken": "YOUR_SECRET"
      }
    }
    Response
    {
      "result": true,
      "errors": [],
      "status": "connected",
      "applied": 1,
      "restart": "scheduled"
    }
  5. 05

    Read the status

    connected, pending (a sign-in not finished), reauth (sign in again) or error. Values and tokens never come back.

    POST /UserAgent/ConnectorList
    {
      "useragentguid": "YOUR_AGENT_GUID"
    }
    Response
    {
      "result": true,
      "errors": [],
      "useragentconnectors": [
        {
          "slug": "meta-ads",
          "title": "Meta Ads",
          "authtype": "provider-oauth",
          "status": "connected",
          "accounts": {},
          "savedvariables": [
            "appid",
            "appsecret"
          ],
          "lasterror": null
        }
      ]
    }
  6. 06

    List the accounts

    After connecting, list what the agent may use. It cannot reach anything else.

    POST /UserAgent/ConnectorAccounts
    {
      "useragentguid": "YOUR_AGENT_GUID",
      "slug": "meta-ads"
    }
    Response
    {
      "result": true,
      "errors": [],
      "pickers": [
        {
          "key": "ad_accounts",
          "label": "Meta ad accounts",
          "multiple": true,
          "candidates": [
            {
              "id": "1234567890",
              "name": "Example account"
            }
          ],
          "selected": []
        },
        {
          "key": "pages",
          "label": "Facebook Pages for ads",
          "multiple": true,
          "candidates": [
            {
              "id": "1234567890",
              "name": "Example account"
            }
          ],
          "selected": []
        }
      ]
    }
  7. 07

    Save the accounts

    Every id is checked against a fresh list, then the agent uses them, with no restart for most changes.

    POST /UserAgent/ConnectorSetAccounts
    {
      "useragentguid": "YOUR_AGENT_GUID",
      "slug": "meta-ads",
      "accounts": {
        "ad_accounts": [
          "1234567890"
        ],
        "pages": [
          "1234567890"
        ]
      }
    }
    Response
    {
      "result": true,
      "errors": [],
      "restart": "scheduled"
    }
  8. 08

    Disconnect

    Revokes a sign-in where the vendor allows it, deletes what the connection holds and removes the connector from the running agent.

    POST /UserAgent/ConnectorDisconnect
    {
      "useragentguid": "YOUR_AGENT_GUID",
      "slug": "meta-ads"
    }
    Response
    {
      "result": true,
      "errors": [],
      "removed": true,
      "revoked": true,
      "restart": "scheduled"
    }
API Reference

Questions

Meta Ads and Wiro FAQ

What can a Meta Ads AI agent do with my ad accounts?

It reads insights for ad accounts, campaigns, ad sets and ads, with breakdowns by age, gender, country, placement and device. It lists campaigns, ad sets, ads, creatives, custom and lookalike audiences and your uploaded media, searches targeting options and estimates audience size. It can upload images and videos, build image, video and carousel creatives for your chosen Pages, create campaigns, ad sets and ads, turn them on or off, change budgets and delete them. Lead form data and access tokens stay out of its reach.

How do I connect Meta Ads to an AI agent?

Meta Ads sits on the agent's Connectors tab, and a request in Chat gets the agent to add it too. There are two ways in. With your own Meta app, type in its App ID and App Secret, then sign in with Facebook in the window that opens. With a key, paste a System User token from Meta Business Settings; no app keys are needed then. Either way, you then pick the ad accounts and Facebook Pages the agent may use.

Should I use a System User token or sign in through my own Meta app?

A System User token belongs to your business rather than to a person, and when Meta offers the option you can set it to never expire, which suits Scheduled Tasks that automate Meta Ads work. Assign the ad accounts to the System User with the ADVERTISE and ANALYZE tasks, plus the Pages you advertise with. Signing in through your own app uses your personal Facebook access instead; Meta's long-lived sign-in lasts about 60 days, after which the connector asks you to sign in again.

Will the agent launch ads or raise budgets without my approval?

Campaigns, ad sets and ads are always created paused, and switching one on is a separate action. In Chat, switching things on, changing budgets and deleting need your approval first by default, and Meta still reviews every ad before it runs. On a schedule, the same actions go ahead by default, so set them to Ask or Block under Scheduled Tasks when every change needs a person's approval. A deleted campaign cannot run again, so pausing is the safer choice when you may want something back.

Which Meta permissions does the connection need?

ads_management, ads_read and business_management for the ad accounts. For creatives that run from a Facebook Page, add pages_show_list, pages_read_engagement and pages_manage_ads. With your own app, enable them under App Review; with a System User token, grant them when you generate the token. The app behind a System User token must not require an app secret proof on every server call.

Can I limit the agent to some ad accounts and Pages?

Yes. After connecting, pick the ad accounts and Facebook Pages the agent may use; it cannot reach any others, and each change is checked against that list before it is sent. On an ad account where your access has only the ANALYZE task, the agent can report but cannot change anything.

Where is my Meta token stored, and what does the connector cost?

The token is kept encrypted, and the AI model works with the results, never with the token itself; an App ID and App Secret only serve the sign-in. No agent plan charges extra for the Meta Ads connector. Meta does not charge for Marketing API calls either, but your ad spend is billed by Meta as usual and Meta's rate limits apply to your app.

Is this a Meta Ads MCP server I need to run myself?

No. Meta Ads works from inside your agent, sending each request straight to Meta's Marketing API with your token, so there is no Meta Ads MCP server for you to install or host.

Access

Revoke Meta Ads access

Remove the app's access in your Meta Ads account's connected apps settings, then disconnect it here.

Related connectors

More ads connectors for your Wiro agent

TikTok Ads logoTikTok Ads logo

TikTok Ads

Campaigns, ad groups, ads, audiences and reports in TikTok Ads Manager.

Google Ads logo

Google Ads

Campaigns, budgets, audiences, assets and performance in Google Ads.

Put Meta Ads to work with Wiro

Deploy an agent and connect Meta Ads from its Connectors tab. Every agent plan includes it: Starter $5, Pro $30 and Max $100 a month.

Build an AgentAll Connectors

Discover, test, and run AI models, build workflows and agents with one unified API.

All systems operational
WiroModelsAgentsMCP ServerLLM GatewayBrowser ExtensionIntegrationsConnectorsPricingAboutBlogCareersContactPartnerChangelogStatusFAQ
CategoriesText to ImageImage to ImageImage EditingImage to TextText to VideoImage to VideoVideo to VideoText to SpeechSpeech to TextSpeech to SpeechVoice CloneRealtime ConversationMusic GenerationLLMUtilities
ModelsNano Banana 2GPT Image 2.5Seedream V5 ProSeedance 2.5Veo 3.1Kling V3FLUX 3FLUX.2 ProWan 3.0 PrimeGrok Imagine 1.5
PartnersGoogleOpenAIByteDanceBlack Forest LabsKling AIQwenAlibabaxAIMiniMaxElevenLabs
Getting StartedWiro ModelsWiro EffectsIntroductionAuthenticationProjectsCode ExamplesWiro MCP ServerSelf-Hosted MCPn8n IntegrationLLMs.txt
API ReferenceModelsRun a ModelModel ParametersTasksLLM & Chat StreamingWebSocketRealtime VoiceFiles
© 2026 Wiro AI. All rights reserved.
PrivacyTermsData Deletion