Get Meta Campaigns by Ad Account
meta_ads_get_campaigns_by_adaccountFetch campaigns from a Meta ad account with filtering by status, objective, or date. Paginate through results to handle large datasets.
Instructions
Retrieve all campaigns from a specific Meta ad account with filtering and pagination.
Args:
act_id (string): Ad account ID prefixed with 'act_', e.g., 'act_1234567890'
fields (string[]): Fields per campaign. Common: id, name, objective, effective_status, created_time, daily_budget, lifetime_budget, budget_remaining
effective_status (string[]): Filter by status: ACTIVE, PAUSED, DELETED, PENDING_REVIEW, DISAPPROVED, PREAPPROVED, PENDING_BILLING_INFO, ARCHIVED, WITH_ISSUES
objective (string[]): Filter by objective: APP_INSTALLS, BRAND_AWARENESS, CONVERSIONS, EVENT_RESPONSES, LEAD_GENERATION, LINK_CLICKS, MESSAGES, PAGE_LIKES, POST_ENGAGEMENT, PRODUCT_CATALOG_SALES, REACH, VIDEO_VIEWS
filtering (object[]): Additional filter objects with field, operator, value
limit (number): Results per page (1-100, default: 25)
after / before (string): Pagination cursors
date_preset / time_range: Date filter for campaigns
updated_since (number): Return campaigns updated since this Unix timestamp
is_completed (boolean): True = only completed, False = only active, null = both
special_ad_categories (string[]): Filter by: EMPLOYMENT, HOUSING, CREDIT, ISSUES_ELECTIONS_POLITICS, NONE
include_drafts (boolean): Include draft campaigns if true
date_format (string): Date format for response
Returns: Object with data (campaign array) and paging. Use meta_ads_fetch_pagination_url with paging.next for more results.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| act_id | Yes | Ad account ID prefixed with 'act_', e.g., 'act_1234567890' | |
| fields | No | List of specific fields to retrieve. If omitted, default fields are returned | |
| filtering | No | List of filter objects. Each has 'field', 'operator', and 'value'. Example: [{field: 'spend', operator: 'GREATER_THAN', value: 50}] | |
| date_preset | No | Predefined relative time range. Options: today, yesterday, this_month, last_month, this_quarter, 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. Default: last_30d. Ignored if time_range, time_ranges, since, or until is provided | |
| time_range | No | Custom time range with since/until dates in YYYY-MM-DD format | |
| updated_since | No | Return campaigns updated since this Unix timestamp | |
| effective_status | No | Filter by effective status. Options: ACTIVE, PAUSED, DELETED, PENDING_REVIEW, DISAPPROVED, PREAPPROVED, PENDING_BILLING_INFO, CAMPAIGN_PAUSED, ARCHIVED, ADSET_PAUSED, IN_PROCESS, WITH_ISSUES | |
| is_completed | No | True = only completed, False = only active, null = both | |
| special_ad_categories | No | Filter by special ad categories: EMPLOYMENT, HOUSING, CREDIT, ISSUES_ELECTIONS_POLITICS, NONE | |
| objective | No | Filter by objective: APP_INSTALLS, BRAND_AWARENESS, CONVERSIONS, EVENT_RESPONSES, LEAD_GENERATION, LINK_CLICKS, MESSAGES, PAGE_LIKES, POST_ENGAGEMENT, PRODUCT_CATALOG_SALES, REACH, VIDEO_VIEWS | |
| buyer_guarantee_agreement_status | No | Filter by buyer guarantee agreement status: APPROVED, NOT_APPROVED | |
| date_format | No | Format for date fields in response. 'U' = Unix timestamp (seconds), 'Y-m-d H:i:s' = MySQL datetime. Default: ISO 8601 | |
| include_drafts | No | Include draft campaigns in results if true | |
| limit | No | Maximum number of results to return per page (1-100, default: 25) | |
| after | No | Cursor for the next page of results, from response.paging.cursors.after | |
| before | No | Cursor for the previous page of results, from response.paging.cursors.before | |
| offset | No | Alternative pagination: number of results to skip |