Metaads

Learn how to use Metaads with Composio

Overview

Enum

METAADS

Description

Meta Ads Marketing API Integration

This tool provides access to Meta’s Marketing API for managing ad campaigns, ad sets, ads, and custom audiences, as well as retrieving insights and analytics.

Authentication Details

client_id
stringRequired
client_secret
stringRequired
oauth_redirect_uri
stringDefaults to https://backend.composio.dev/api/v1/auth-apps/add
scopes
stringDefaults to ads_read,ads_management
api_token
stringRequired

Actions

Create a new ad within an ad set using the meta marketing api. supports various ad formats including image, video, carousel, and collection ads.

Action Parameters

ad_set_id
stringRequired
bid_amount
integer
creative
objectRequired
name
stringRequired
status
stringDefaults to PAUSED
tracking_specs
array

Action Response

data
object
error
successful
boolean

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

Action Parameters

account_id
stringRequired
creative
objectRequired
name
stringRequired

Action Response

data
object
error
successful
boolean

Create a new ad set within a campaign using the meta marketing api. supports detailed targeting options, budgets, and optimization goals.

Action Parameters

bid_amount
integerRequired
billing_event
stringRequired
campaign_id
stringRequired
daily_budget
number
end_time
string
lifetime_budget
number
name
stringRequired
optimization_goal
stringRequired
start_time
string
status
stringDefaults to PAUSED
targeting
objectRequired

Action Response

data
object
error
successful
boolean

Create a new advertising campaign using the meta marketing api. supports various campaign objectives, budgets, and bidding strategies.

Action Parameters

account_id
stringRequired
bid_strategy
stringDefaults to LOWEST_COST_WITHOUT_CAP
daily_budget
number
lifetime_budget
number
name
stringRequired
objective
stringRequired
special_ad_categories
array
status
stringDefaults to PAUSED

Action Response

data
object
error
successful
boolean

Create a new custom audience using the meta marketing api. supports various types of custom audiences including customer lists, website visitors, and app users.

Action Parameters

account_id
stringRequired
content_type
string
customer_file
array
customer_file_source
string
description
string
name
stringRequired
prefill
booleanDefaults to True
retention_days
integer
rule
object
subtype
stringRequired

Action Response

data
object
error
successful
boolean

Delete ad creative

Action Parameters

creative_id
stringRequired

Action Response

data
object
error
successful
boolean

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.

Action Parameters

campaign_id
stringRequired

Action Response

data
object
error
successful
boolean

Get ad creative

Action Parameters

creative_id
stringRequired
fields
arrayDefaults to ['id', 'name', 'status', 'object_story_spec']

Action Response

data
object
error
successful
boolean

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.

Action Parameters

action_attribution_windows
arrayDefaults to ['7d_click', '1d_view']
breakdowns
array
date_preset
string
fields
arrayDefaults to ['impressions', 'clicks', 'spend']
filtering
array
level
stringDefaults to account
object_id
stringRequired
sort
array
time_range
object

Action Response

data
array
error
paging
successful
boolean

Pause an advertising campaign using the meta marketing api. this stops the campaign from delivering ads but allows it to be resumed later. all child ad sets and ads will also be paused with an effective status of campaign paused.

Action Parameters

campaign_id
stringRequired

Action Response

data
object
error
successful
boolean

Preview ad creative

Action Parameters

creative_id
stringRequired
thumbnail_height
integerDefaults to 120
thumbnail_width
integerDefaults to 150

Action Response

data
object
error
successful
boolean

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.

Action Parameters

ad_account_id
stringRequired
date_preset
string
effective_status
array
fields
arrayDefaults to ['name', 'id', 'status']
is_completed
boolean
limit
integerDefaults to 50
time_range_since
string
time_range_until
string
updated_since
integer

Action Response

data
array
error
paging_next
paging_previous
successful
boolean
total_count

Resume a paused advertising campaign using the meta marketing api. this sets the campaign status to active so it can deliver ads again. note that child ad sets and ads that were previously active will also resume delivery, but those that were individually paused will remain paused.

Action Parameters

campaign_id
stringRequired

Action Response

data
object
error
successful
boolean

Update ad creative

Action Parameters

creative_id
stringRequired
name
string
status
string

Action Response

data
object
error
successful
boolean

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.

Action Parameters

bid_strategy
string
campaign_id
stringRequired
daily_budget
number
lifetime_budget
number
name
string
special_ad_categories
array
spend_cap
number
status
string

Action Response

data
object
error
successful
boolean

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.

Action Parameters

ad_account_id
stringRequired
image
objectRequired
name
string

Action Response

data
object
error
successful
boolean