# Metaads

```json
{
  "name": "Metaads",
  "slug": "metaads",
  "url": "https://composio.dev/toolkits/metaads",
  "markdown_url": "https://composio.dev/toolkits/metaads.md",
  "logo_url": "https://logos.composio.dev/api/metaads",
  "categories": [
    "advertising & marketing"
  ],
  "is_composio_managed": false,
  "updated_at": "2026-05-12T10:18:48.732Z"
}
```

![Metaads logo](https://logos.composio.dev/api/metaads)

## Description

Securely connect your AI agents and chatbots (Claude, ChatGPT, Cursor, etc) with Metaads MCP or direct API to create campaigns, pull ad performance data, update budgets, and generate custom reports through natural language.

## Summary

Metaads is Meta's official Ads API that lets you manage, analyze, and optimize your Facebook and Instagram ad campaigns. Streamline ad operations and gain deeper insights with robust automation.

## Categories

- advertising & marketing

## Toolkit Details

- Tools: 50

## Images

- Logo: https://logos.composio.dev/api/metaads

## Authentication

- **Oauth2**
  - Type: `oauth2`
  - Description: Oauth2 authentication for Meta Ads.
  - Setup:
    - Configure Oauth2 credentials for Meta Ads.
    - Use the credentials when creating an auth config in Composio.
- **Api Key**
  - Type: `api_key`
  - Description: Api Key authentication for Meta Ads.
  - Setup:
    - Configure Api Key credentials for Meta Ads.
    - Use the credentials when creating an auth config in Composio.

## Suggested Prompts

- Get ad performance insights for last week
- Create a new campaign for summer sale
- Pause all ads in underperforming campaigns
- Build a custom audience from website visitors

## Supported Tools

| Tool slug | Name | Description |
|---|---|---|
| `METAADS_CREATE_AD` | Create Ad | Create a new ad within an ad set using the Meta Marketing API. Supports various ad formats including image, video, carousel, and collection ads. |
| `METAADS_CREATE_AD_CREATIVE` | Create Ad Creative | Create a new ad creative using the Meta Marketing API. Ad creatives are reusable visual and interactive elements that define how your ad looks and behaves: - Can be used in multiple ads - Support various formats (image, video, carousel) - Include text, media, and call-to-action buttons - Must follow Meta's ad policies |
| `METAADS_CREATE_AD_SET` | Create Ad Set | Create a new ad set within a campaign using the Meta Marketing API. Supports detailed targeting options, budgets, and optimization goals. |
| `METAADS_CREATE_CAMPAIGN` | Create Campaign | Create a new advertising campaign using the Meta Marketing API. Supports various campaign objectives, budgets, and bidding strategies. |
| `METAADS_CREATE_CUSTOM_AUDIENCE` | Create Custom Audience | Create a new custom audience using the Meta Marketing API. Supports various types of custom audiences including customer lists, website visitors, and app users. |
| `METAADS_DELETE_CAMPAIGN` | Delete Campaign | Delete an advertising campaign using the Meta Marketing API. This marks the campaign as DELETED, which prevents it from delivering ads. Note that deleted campaigns are not permanently removed from Meta's systems and can still be viewed in reports. |
| `METAADS_GET_AD_ACCOUNTS` | Get Ad Accounts | Tool to retrieve all ad account IDs accessible to the authenticated user from Meta Ads. Use when you need to get a user's ad account information including account IDs, names, and other account details. |
| `METAADS_GET_AD_CREATIVE` | Get Ad Creative | Get Ad Creative |
| `METAADS_GET_INSIGHTS` | Get Insights | Get insights data for a Meta Ads object (ad account, campaign, ad set, or ad) using the Meta Marketing API. Supports various metrics, breakdowns, and filtering options with flexible date ranges. Results are paginated; follow `paging.cursors.after` or `paging.next` to retrieve all rows. Missing metric values in results should not be assumed to be zero. |
| `METAADS_GET_OBJECT` | Get Meta Object | Tool to retrieve data for any Meta Marketing API object by its ID. Use when you need to get information about a specific ad account, campaign, ad set, ad, ad creative, page, user, or other Meta object. Supports flexible field selection to retrieve only the data you need. |
| `METAADS_GET_PAGE_ACCOUNTS` | Get Page Accounts | Tool to retrieve permanent page access tokens for accounts managed by the user. Use when you need to get pages the user manages along with access tokens for each page. |
| `METAADS_GET_USER` | Get User | Tool to retrieve information about the authenticated user from Meta (Facebook) Graph API. Use when you need to get the current user's profile information such as name, email, or other user details. |
| `METAADS_LIST_AD_CREATIVES` | List Ad Creatives | Tool to list all ad creatives under an ad account. Use when you need to retrieve multiple ad creatives from a Meta Ads account to view, analyze, or manage creative assets. |
| `METAADS_LIST_AD_NETWORK_ANALYTICS` | List Ad Network Analytics | Tool to retrieve ad network analytics for a Meta Business using the Meta Marketing API. Use when you need to get ad network performance metrics such as revenue or impressions. |
| `METAADS_LIST_AD_NETWORK_ANALYTICS_RESULTS` | List Ad Network Analytics Results | Tool to retrieve ad network analytics results for Facebook Audience Network. Use when you need to get performance data from ads displayed through Facebook Audience Network on third-party apps and websites for a specific business, app, or property. |
| `METAADS_LIST_ADS` | List Ads | Tool to list all ads under an ad account using the Meta Marketing API. Use when you need to retrieve ads from a specific ad account with optional filtering by fields. |
| `METAADS_LIST_AGENCIES` | List Agencies | Tool to retrieve agencies associated with a Meta Business or Ad Account. Use when you need to get the list of agencies that have access to manage a specific business or ad account. |
| `METAADS_LIST_ASSIGNED_PAGES` | List Assigned Pages | Tool to retrieve Facebook Pages assigned to a business user via Meta Marketing API. Use when you need to get the list of pages a business user has access to. |
| `METAADS_LIST_ASSIGNED_USERS` | List Assigned Users | Tool to list users assigned to a Facebook Page or Ad Account within a specific business context. Use when you need to retrieve the list of users who have access to a Page or Ad Account and their associated task permissions. |
| `METAADS_LIST_BUSINESS_AD_ACCOUNTS` | List Business Ad Accounts | Tool to retrieve all ad accounts owned by a specific Business Manager. Use when you need to get ad account information for a business including account IDs, names, and status. |
| `METAADS_LIST_BUSINESS_INVOICES` | List Business Invoices | Tool to retrieve business invoices from Meta Marketing API. Use when you need to fetch invoice data for a business including amounts, due dates, and payment status. |
| `METAADS_LIST_CLIENT_AD_ACCOUNTS` | List Client Ad Accounts | Tool to list all client ad accounts accessible to a business from Meta Ads. Use when you need to retrieve ad accounts that have been shared with a Business Manager as clients. |
| `METAADS_LIST_CLIENT_APPS` | List Client Apps | Tool to retrieve client apps associated with a Meta Business using the Marketing API. Use when you need to get information about apps linked to a specific business. |
| `METAADS_LIST_CLIENT_INSTAGRAM_ASSETS` | List Client Instagram Assets | Tool to retrieve Instagram assets that are shared with a business as a client using the Meta Marketing API. Use when you need to fetch Instagram accounts or assets linked to a specific business ID. |
| `METAADS_LIST_CLIENT_OFFSITE_SIGNAL_CONTAINERS` | List Client Offsite Signal Container Business Objects | Tool to retrieve client offsite signal container business objects for a business from Meta Marketing API. Use when you need to list all client offsite signal container business objects associated with a specific business ID. |
| `METAADS_LIST_CLIENT_PAGES` | List Client Pages | Tool to retrieve client pages associated with a Meta business. Use when you need to get the list of pages that a business manages on behalf of clients. |
| `METAADS_LIST_CLIENTS` | List Clients | Tool to retrieve client businesses associated with a Meta Business Manager. Use when you need to get the list of businesses that are clients of a specific Business Manager. |
| `METAADS_LIST_COLLABORATIVE_ADS_COLLABORATION_REQUESTS` | List Collaborative Ads Collaboration Requests | Tool to retrieve collaborative ads collaboration requests for a Meta Business using the Marketing API. Use when you need to get collaboration requests related to collaborative advertising partnerships for a specific business. |
| `METAADS_LIST_COLLABORATIVE_ADS_SUGGESTED_PARTNERS` | List Collaborative Ads Suggested Partners | Tool to retrieve collaborative ads suggested partners for a business from Meta Marketing API. Use when you need to discover potential partnership opportunities for collaborative advertising campaigns. |
| `METAADS_LIST_INITIATED_AUDIENCE_SHARING_REQUESTS` | List Initiated Audience Sharing Requests | Tool to retrieve initiated audience sharing requests for a business using the Meta Marketing API. Use when you need to get the list of audience sharing requests that have been initiated by a business. |
| `METAADS_LIST_MANAGED_PARTNER_ADS_FUNDING_SOURCE_DETAILS` | List Managed Partner Ads Funding Source Details | Tool to retrieve managed partner ads funding source details for a Meta Business. Use when you need to get funding source information for managed partner ads associated with a specific business. |
| `METAADS_LIST_OWNED_APPS` | List Owned Apps | Tool to retrieve apps owned by a business from Meta Marketing API. Use when you need to get information about apps associated with a business account. |
| `METAADS_LIST_OWNED_BUSINESSES` | List Owned Businesses | Tool to retrieve businesses owned by a parent Business Manager from Meta Marketing API. Use when you need to list child businesses managed under a Business Manager account in a Tier-2 business hierarchy. |
| `METAADS_LIST_OWNED_INSTAGRAM_ASSETS` | List Owned Instagram Assets | Tool to list Instagram accounts/assets owned by a Meta Business. Use when you need to retrieve the Instagram Business Accounts associated with a specific Meta Business. |
| `METAADS_LIST_OWNED_OFFSITE_SIGNAL_CONTAINER_BUSINESS_OBJECTS` | List Owned Offsite Signal Container Business Objects | Tool to retrieve owned offsite signal container business objects for a business from Meta Marketing API. Use when you need to list all owned offsite signal container business objects associated with a specific business ID. |
| `METAADS_LIST_OWNED_PAGES` | List Owned Pages | Tool to retrieve Pages owned by a Business Manager from Meta Marketing API. Use when you need to get a list of all Facebook Pages that a business owns or manages. |
| `METAADS_LIST_PENDING_CLIENT_AD_ACCOUNTS` | List Pending Client Ad Accounts | Tool to retrieve pending client ad account access requests for a Business Manager from Meta Ads. Use when you need to get ad accounts that are awaiting approval to be added as clients to a business. |
| `METAADS_LIST_PENDING_CLIENT_APPS` | List Pending Client Apps | Tool to retrieve pending client apps for a Meta Business. Use when you need to list apps that are pending approval or connection to a business account. |
| `METAADS_LIST_PENDING_CLIENT_PAGES` | List Pending Client Pages | Tool to retrieve pending client pages for a Business Manager using the Meta Marketing API. Use when you need to see which Facebook Pages have pending access requests from the business. |
| `METAADS_LIST_PENDING_OFFSITE_SIGNAL_CONTAINERS` | List Pending Shared Offsite Signal Container Business Objects | Tool to retrieve pending shared offsite signal container business objects from Meta Marketing API. Use when you need to get information about pending shared offsite signal containers associated with a business account. |
| `METAADS_LIST_PENDING_OWNED_AD_ACCOUNTS` | List Pending Owned Ad Accounts | Tool to retrieve pending owned ad accounts for a Business Manager account from Meta Marketing API. Use when you need to list ad accounts with pending ownership status for a specific business. |
| `METAADS_LIST_PENDING_OWNED_PAGES` | List Pending Owned Pages | Tool to retrieve Pages with pending ownership status for a Business Manager from Meta Marketing API. Use when you need to get a list of Facebook Pages that are pending approval or verification for a business to own. |
| `METAADS_LIST_PENDING_USERS` | List Pending Users | Tool to retrieve pending users from a Business Manager in Meta Marketing API. Use when you need to get information about users with pending invitations to a Business Manager. |
| `METAADS_LIST_RECEIVED_AUDIENCE_SHARING_REQUESTS` | List Received Audience Sharing Requests | Tool to retrieve all received audience sharing requests for a business using the Meta Marketing API. Use when you need to see which other businesses have requested to share custom audiences with your business. |
| `METAADS_LIST_SYSTEM_USERS` | List System Users | Tool to retrieve system users for a Meta Business Manager account. Use when you need to list all system users (non-human accounts used for API access) associated with a business. |
| `METAADS_LIST_TARGETING_SEARCH` | List Targeting Search | Tool to search for targeting options in Meta Ads Marketing API. Use when you need to find interests, locations, demographics, schools, or employers for ad targeting purposes. |
| `METAADS_READ_ADSETS` | Read Ad Sets | Retrieve ad sets from a Meta ad account using the Marketing API. Returns information about the ad sets including their status, targeting, and other properties. |
| `METAADS_UPDATE_AD_CREATIVE` | Update Ad Creative | Update Ad Creative |
| `METAADS_UPDATE_CAMPAIGN` | Update Campaign | Update an existing advertising campaign using the Meta Marketing API. Allows modification of campaign properties like name, status, budget, and bidding strategy. Only the fields that need to be updated should be included in the request. |
| `METAADS_UPLOAD_AD_IMAGE` | Upload Ad Image | Upload an image for use in Meta ad creatives using the Marketing API. The image can later be referenced by its hash when creating ad creatives. |

## Supported Triggers

None listed.

## Installation and MCP Setup

### Path 1: SDK Installation

#### Path 1, Step 1: Install Composio

Install the Composio SDK
```python
pip install composio_openai
```

```typescript
npm install @composio/openai
```

#### Path 1, Step 2: Initialize Composio and Create Tool Router Session

Import and initialize Composio client, then create a Tool Router session
```python
from openai import OpenAI
from composio import Composio
from composio_openai import OpenAIResponsesProvider

composio = Composio(provider=OpenAIResponsesProvider())
openai = OpenAI()
session = composio.create(user_id='your-user-id')
```

```typescript
import OpenAI from 'openai';
import { Composio } from '@composio/core';
import { OpenAIResponsesProvider } from '@composio/openai';

const composio = new Composio({
  provider: new OpenAIResponsesProvider(),
});
const openai = new OpenAI({});
const session = await composio.create('your-user-id');
```

#### Path 1, Step 3: Execute Metaads Tools via Tool Router with Your Agent

Get tools from Tool Router session and execute Metaads actions with your Agent
```python
tools = session.tools
response = openai.responses.create(
  model='gpt-4.1',
  tools=tools,
  input=[{
    'role': 'user',
    'content': 'Get insights for my latest ad campaign this week'
  }]
)
result = composio.provider.handle_tool_calls(
  response=response,
  user_id='your-user-id'
)
print(result)
```

```typescript
const tools = session.tools;
const response = await openai.responses.create({
  model: 'gpt-4.1',
  tools: tools,
  input: [{
    role: 'user',
    content: 'Get insights for my latest ad campaign this week'
  }],
});
const result = await composio.provider.handleToolCalls(
  'your-user-id',
  response.output
);
console.log(result);
```

### Path 2: MCP Server Setup

#### Path 2, Step 1: Install Composio

Install the Composio SDK and Claude Agent SDK
```python
pip install composio claude-agent-sdk
```

```typescript
npm install @composio/core ai @ai-sdk/openai @ai-sdk/mcp
```

#### Path 2, Step 2: Create Tool Router Session

Initialize the Composio client and create a Tool Router session
```python
from composio import Composio
from claude_agent_sdk import ClaudeSDKClient, ClaudeAgentOptions

composio = Composio(api_key='your-composio-api-key')
session = composio.create(user_id='your-user-id')
url = session.mcp.url
```

```typescript
import { Composio } from '@composio/core';

const composio = new Composio({ apiKey: 'your-api-key' });

console.log("Creating Tool Router session...");
const { mcp } = await composio.create('your-user-id');
console.log(`Tool Router session created: ${mcp.url}`);
```

#### Path 2, Step 3: Connect to AI Agent

Use the MCP server with your AI agent
```python
import asyncio

options = ClaudeAgentOptions(
    permission_mode='bypassPermissions',
    mcp_servers={
        'tool_router': {
            'type': 'http',
            'url': url,
            'headers': {
                'x-api-key': 'your-composio-api-key'
            }
        }
    },
    system_prompt='You are a helpful assistant with access to Metaads tools.',
    max_turns=10
)

async def main():
    async with ClaudeSDKClient(options=options) as client:
        await client.query('Get insights for campaign 12345 from last week')
        async for message in client.receive_response():
            if hasattr(message, 'content'):
                for block in message.content:
                    if hasattr(block, 'text'):
                        print(block.text)

asyncio.run(main())
```

```typescript
import { openai } from '@ai-sdk/openai';
import { experimental_createMCPClient as createMCPClient } from '@ai-sdk/mcp';
import { generateText, stepCountIs } from 'ai';

const client = await createMCPClient({
  transport: {
    type: 'http',
    url: mcp.url,
    headers: { 'x-api-key': 'your-composio-api-key' }
  }
});

const tools = await client.tools();

const { text } = await generateText({
  model: openai('gpt-4o'),
  tools,
  messages: [{ role: 'user', content: 'Get insights for campaign 12345 from last week' }],
  stopWhen: stepCountIs( 5 )
});

console.log(`Agent: ${text}`);
```

## Why Use Composio?

### 1. AI Native Metaads Integration

- Supports both Metaads MCP and direct API based integrations
- Structured, LLM-friendly schemas for reliable tool execution
- Rich coverage for reading, writing, and querying your Metaads data

### 2. Managed Auth

- Built-in OAuth handling with automatic token refresh and rotation
- Central place to manage, scope, and revoke Metaads access
- Per user and per environment credentials instead of hard-coded keys

### 3. Agent Optimized Design

- Tools are tuned using real error and success rates to improve reliability over time
- Comprehensive execution logs so you always know what ran, when, and on whose behalf

### 4. Enterprise Grade Security

- Fine-grained RBAC so you control which agents and users can access Metaads
- Scoped, least privilege access to Metaads resources
- Full audit trail of agent actions to support review and compliance

## Use Metaads with any AI Agent Framework

Choose a framework you want to connect Metaads with:

- [ChatGPT](https://composio.dev/toolkits/metaads/framework/chatgpt)
- [OpenAI Agents SDK](https://composio.dev/toolkits/metaads/framework/open-ai-agents-sdk)
- [Claude Agent SDK](https://composio.dev/toolkits/metaads/framework/claude-agents-sdk)
- [Claude Code](https://composio.dev/toolkits/metaads/framework/claude-code)
- [Claude Cowork](https://composio.dev/toolkits/metaads/framework/claude-cowork)
- [Codex](https://composio.dev/toolkits/metaads/framework/codex)
- [Cursor](https://composio.dev/toolkits/metaads/framework/cursor)
- [VS Code](https://composio.dev/toolkits/metaads/framework/vscode)
- [OpenCode](https://composio.dev/toolkits/metaads/framework/opencode)
- [OpenClaw](https://composio.dev/toolkits/metaads/framework/openclaw)
- [Hermes](https://composio.dev/toolkits/metaads/framework/hermes-agent)
- [CLI](https://composio.dev/toolkits/metaads/framework/cli)
- [Google ADK](https://composio.dev/toolkits/metaads/framework/google-adk)
- [LangChain](https://composio.dev/toolkits/metaads/framework/langchain)
- [Vercel AI SDK](https://composio.dev/toolkits/metaads/framework/ai-sdk)
- [Mastra AI](https://composio.dev/toolkits/metaads/framework/mastra-ai)
- [LlamaIndex](https://composio.dev/toolkits/metaads/framework/llama-index)
- [CrewAI](https://composio.dev/toolkits/metaads/framework/crew-ai)
- [Pydantic AI](https://composio.dev/toolkits/metaads/framework/pydantic-ai)
- [AutoGen](https://composio.dev/toolkits/metaads/framework/autogen)

## Related Toolkits

- [Adrapid](https://composio.dev/toolkits/adrapid) - Adrapid is a platform for rapid creation of digital marketing visuals using templates. It streamlines design workflows for banners, images, and HTML5 content with automation.
- [Adyntel](https://composio.dev/toolkits/adyntel) - Adyntel is an API that retrieves LinkedIn ads for any company using a domain or LinkedIn Page ID. Easily access competitive ad intelligence to power your marketing workflows.
- [Beaconstac](https://composio.dev/toolkits/beaconstac) - Beaconstac is a platform for creating and managing QR codes and proximity beacons. It helps businesses engage customers and track marketing performance with powerful analytics.
- [Campaign cleaner](https://composio.dev/toolkits/campaign_cleaner) - Campaign cleaner is an email campaign optimization tool that boosts compatibility and deliverability across email clients. It helps marketers get better results by cleaning, enhancing, and ensuring high performance for every campaign.
- [Deadline funnel](https://composio.dev/toolkits/deadline_funnel) - Deadline Funnel lets you create personalized deadlines and timers for your marketing campaigns. It helps marketers boost conversions by adding authentic urgency to offers.
- [Google Ads](https://composio.dev/toolkits/googleads) - Google Ads is Google's online advertising platform for creating, managing, and optimizing digital campaigns. It helps businesses reach targeted customers and maximize return on ad spend.
- [Instantly](https://composio.dev/toolkits/instantly) - Instantly is a platform for automating cold email outreach, managing leads, and optimizing deliverability. Get better results from email campaigns with minimal manual effort.
- [Proofly](https://composio.dev/toolkits/proofly) - Proofly is a social proof platform that displays real-time notifications of customer activity on your site. It helps you increase website conversions by building trust and urgency for visitors.
- [Segmetrics](https://composio.dev/toolkits/segmetrics) - Segmetrics is a marketing analytics platform that reveals detailed insights into your customer journeys. It helps businesses optimize marketing strategies with accurate, actionable reporting.
- [Semrush](https://composio.dev/toolkits/semrush) - Semrush is a leading SEO tool suite for keyword research, competitor analysis, and campaign tracking. It empowers marketers to improve search rankings and optimize online visibility.
- [Sendloop](https://composio.dev/toolkits/sendloop) - Sendloop is an all-in-one email marketing platform built for SaaS, e-commerce, and small businesses. It makes it easy to send campaigns, manage lists, and track results—all in one place.
- [Sidetracker](https://composio.dev/toolkits/sidetracker) - Sidetracker is a marketing analytics platform that tracks expenses, sales funnels, and customer journeys. It helps optimize marketing spend and visualize campaign performance from start to finish.
- [Stannp](https://composio.dev/toolkits/stannp) - Stannp is an API-driven direct mail platform for sending postcards and letters programmatically. It lets you automate physical mail delivery—no manual printing or mailing required.
- [Tapfiliate](https://composio.dev/toolkits/tapfiliate) - Tapfiliate is an affiliate and referral tracking platform for businesses. It helps companies efficiently manage, track, and grow their affiliate programs.
- [Tpscheck](https://composio.dev/toolkits/tpscheck) - Tpscheck is a real-time service for verifying UK phone numbers against TPS and CTPS registers. It helps prevent unwanted marketing calls and ensures compliance with UK telemarketing laws.
- [Gmail](https://composio.dev/toolkits/gmail) - Gmail is Google's email service with powerful spam protection, search, and G Suite integration. It keeps your inbox organized and makes communication fast and reliable.
- [Google Calendar](https://composio.dev/toolkits/googlecalendar) - Google Calendar is a time management service for scheduling meetings, events, and reminders. It streamlines personal and team organization with integrated notifications and sharing options.
- [Google Drive](https://composio.dev/toolkits/googledrive) - Google Drive is a cloud storage platform for uploading, sharing, and collaborating on files. It's perfect for keeping your documents accessible and organized across devices.
- [Outlook](https://composio.dev/toolkits/outlook) - Outlook is Microsoft's email and calendaring platform for unified communications and scheduling. It helps users stay organized with powerful email, contacts, and calendar management.
- [Twitter](https://composio.dev/toolkits/twitter) - Twitter is a social media platform for sharing real-time updates, conversations, and news. Stay connected, informed, and engaged with communities worldwide.

## Frequently Asked Questions

### Do I need my own developer credentials to use Metaads with Composio?

Yes, Metaads requires you to configure your own OAuth credentials. Once set up, Composio handles token storage, refresh, and lifecycle management for you.

### Can I use multiple toolkits together?

Yes! Composio's Tool Router enables agents to use multiple toolkits. [Learn more](https://docs.composio.dev/tool-router/overview).

### Is Composio secure?

Composio is SOC 2 and ISO 27001 compliant with all data encrypted in transit and at rest. [Learn more](https://trust.composio.dev).

### What if the API changes?

Composio maintains and updates all toolkit integrations automatically, so your agents always work with the latest API versions.

---
[See all toolkits](https://composio.dev/toolkits) · [Composio docs](https://docs.composio.dev/llms.txt)
