Skip to main content
Glama

meta_ads_audiences_create

Create a Custom Audience in Meta Ads to target website visitors, customer lists, or app users. Define audience rules, retention, and data source. Returns audience ID for ad campaigns.

Instructions

Creates a Custom Audience in a Meta Ads account. Returns the new audience_id. Mutating, reversible via rollback_apply (rollback deletes the audience). Subtype controls the data source: WEBSITE audiences require a pixel_id and an event rule; CUSTOM audiences accept a manually supplied rule or a customer list upload (the upload path is handled out-of-band by Meta). For similarity-expanded reach use meta_ads_audiences_create_lookalike on top of this audience.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
account_idNoMeta Ads account ID in the format 'act_XXXXXXXXXX' (e.g. 'act_1234567890'). Optional — falls back to META_ADS_ACCOUNT_ID from the configured credentials. The leading 'act_' prefix is required.
nameYesAudience name shown in Ads Manager. Must be unique within the account.
subtypeNoAudience type hint. WEBSITE auto-generates a PageView rule from the linked pixel when `rule` is omitted; CUSTOM requires an explicit rule or a customer-list upload; APP requires an app_id. Default CUSTOM when omitted.
descriptionNoOptional free-text description stored with the audience. Not visible to end users.
retention_daysNoHow long a matched user stays in the audience after their last qualifying event. Default 30. Meta caps at 180 days.
pixel_idNoMeta Pixel ID to source events from. Required for subtype=WEBSITE. Find via meta_ads.pixels.list.
ruleNoAudience rule definition (Meta rule JSON schema). When omitted with subtype=WEBSITE, a default PageView rule scoped to the supplied pixel is auto-generated. See Meta Marketing API docs for rule syntax — supports url filters, event parameters, and compound boolean operators.
customer_file_sourceNoSource declaration required by Meta for compliance. USER_PROVIDED_ONLY (default) — data came from the advertiser's own first-party sources; PARTNER — from a data provider; BOTH — mixed. Meta uses this to set legal-basis defaults.
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It discloses that the tool is mutating and reversible via rollback_apply (which deletes the audience). It also explains the behavior of different subtypes: WEBSITE auto-generates rule if omitted, CUSTOM requires explicit rule or upload. It mentions retention_days limits (1-180, default 30).

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single paragraph but is reasonably concise and front-loaded with the tool's purpose. It covers key points without unnecessary verbosity. However, it could be structured more clearly (e.g., separating subtype details).

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity (8 parameters, nested rule object, subtypes, compliance requirements), the description covers most aspects: output (returns audience_id), reversibility, subtype behavior, and links to lookalike. No output schema is present, so the description explains the return value. It is fairly complete for a mutation tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage. The description adds context beyond the schema by explaining that rule can be auto-generated for WEBSITE, that customer_file_source is for compliance, that pixel_id can be found via meta_ads.pixels.list, and that account_id requires 'act_' prefix. This adds meaningful value.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it creates a Custom Audience in a Meta Ads account and returns the audience_id. It explains the subtypes (WEBSITE vs CUSTOM) and distinguishes from the sibling tool meta_ads_audiences_create_lookalike by mentioning it is for similarity-expanded reach.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides guidance on when to use this tool vs alternatives, such as using meta_ads_audiences_create_lookalike for similarity-expanded reach. It also explains when to use WEBSITE vs CUSTOM subtypes. However, it does not explicitly mention when not to use this tool (e.g., for listing audiences).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/logly/mureo'

If you have feedback or need assistance with the MCP directory API, please join our Discord server