Server Configuration
Describes the environment variables required to run the server.
Name | Required | Description | Default |
---|---|---|---|
META_APP_ID | No | Your Meta App ID (Client ID) - for direct OAuth method | |
PIPEBOARD_API_TOKEN | No | Your Pipeboard API token for Meta Ads authentication. Token obtainable via https://pipeboard.co |
Schema
Prompts
Interactive templates invoked by user choice
Name | Description |
---|---|
No prompts |
Resources
Contextual data attached and managed by the client
Name | Description |
---|---|
meta-ads://resources |
Tools
Functions exposed to the LLM to take actions
Name | Description |
---|---|
get_ad_accounts | Copy Get ad accounts accessible by a user.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
user_id: Meta user ID or "me" for the current user
limit: Maximum number of accounts to return (default: 10) |
get_account_info | Copy Get detailed information about a specific ad account.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
account_id: Meta Ads account ID (format: act_XXXXXXXXX) |
get_campaigns | Copy Get campaigns for a Meta Ads account with optional filtering.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
account_id: Meta Ads account ID (format: act_XXXXXXXXX)
limit: Maximum number of campaigns to return (default: 10)
status_filter: Filter by status (empty for all, or 'ACTIVE', 'PAUSED', etc.) |
get_campaign_details | Copy Get detailed information about a specific campaign.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
campaign_id: Meta Ads campaign ID |
create_campaign | Copy Create a new campaign in a Meta Ads account.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
account_id: Meta Ads account ID (format: act_XXXXXXXXX)
name: Campaign name
objective: Campaign objective (AWARENESS, TRAFFIC, ENGAGEMENT, etc.)
status: Initial campaign status (default: PAUSED)
special_ad_categories: List of special ad categories if applicable
daily_budget: Daily budget in account currency (in cents)
lifetime_budget: Lifetime budget in account currency (in cents) |
get_adsets | Copy Get ad sets for a Meta Ads account with optional filtering by campaign.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
account_id: Meta Ads account ID (format: act_XXXXXXXXX)
limit: Maximum number of ad sets to return (default: 10)
campaign_id: Optional campaign ID to filter by |
get_adset_details | Copy Get detailed information about a specific ad set.
Args:
adset_id: Meta Ads ad set ID (required)
access_token: Meta API access token (optional - will use cached token if not provided)
Example:
To call this function through MCP, pass the adset_id as the first argument:
{
"args": "YOUR_ADSET_ID"
} |
update_adset | Copy Update an ad set with new settings including frequency caps.
Args:
adset_id: Meta Ads ad set ID
frequency_control_specs: List of frequency control specifications
(e.g. [{"event": "IMPRESSIONS", "interval_days": 7, "max_frequency": 3}])
bid_strategy: Bid strategy (e.g., 'LOWEST_COST_WITH_BID_CAP')
bid_amount: Bid amount in account currency (in cents for USD)
status: Update ad set status (ACTIVE, PAUSED, etc.)
targeting: Targeting specifications including targeting_automation
(e.g. {"targeting_automation":{"advantage_audience":1}})
optimization_goal: Conversion optimization goal (e.g., 'LINK_CLICKS', 'CONVERSIONS', 'APP_INSTALLS', etc.)
access_token: Meta API access token (optional - will use cached token if not provided) |
get_ads | Copy Get ads for a Meta Ads account with optional filtering.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
account_id: Meta Ads account ID (format: act_XXXXXXXXX)
limit: Maximum number of ads to return (default: 10)
campaign_id: Optional campaign ID to filter by
adset_id: Optional ad set ID to filter by |
get_ad_details | Copy Get detailed information about a specific ad.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
ad_id: Meta Ads ad ID |
get_ad_creatives | Copy Get creative details for a specific ad. Best if combined with get_ad_image to get the full image.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
ad_id: Meta Ads ad ID |
get_ad_image | Copy Get, download, and visualize a Meta ad image in one step. Useful to see the image in the LLM.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
ad_id: Meta Ads ad ID
Returns:
The ad image ready for direct visual analysis |
update_ad | Copy Update an ad with new settings.
Args:
ad_id: Meta Ads ad ID
status: Update ad status (ACTIVE, PAUSED, etc.)
bid_amount: Bid amount in account currency (in cents for USD)
access_token: Meta API access token (optional - will use cached token if not provided) |
get_insights | Copy Get performance insights for a campaign, ad set, ad or account.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
object_id: ID of the campaign, ad set, ad or account
time_range: Time range for insights (default: last_30_days, options: today, yesterday, this_month, last_month, this_quarter, maximum, data_maximum, last_3d, last_7d, last_14d, last_28d, last_30d, last_90d, last_week_mon_sun, last_week_sun_sat, last_quarter, last_year, this_week_mon_today, this_week_sun_today, this_year)
breakdown: Optional breakdown dimension (e.g., age, gender, country)
level: Level of aggregation (ad, adset, campaign, account) |
debug_image_download | Copy Debug image download issues and report detailed diagnostics.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
url: Direct image URL to test (optional)
ad_id: Meta Ads ad ID (optional, used if url is not provided) |
save_ad_image_via_api | Copy Try to save an ad image by using the Marketing API's attachment endpoints.
This is an alternative approach when direct image download fails.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
ad_id: Meta Ads ad ID |
get_login_link | Copy Get a clickable login link for Meta Ads authentication.
NOTE: This method should only be used if you're using your own Facebook app.
If using Pipeboard authentication (recommended), set the PIPEBOARD_API_TOKEN
environment variable instead (token obtainable via https://pipeboard.co).
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
Returns:
A clickable resource link for Meta authentication |