Skip to main content
POST
/
v1
/
facebook
/
fetch_search_ads_pages
Fetch Search Ads Pages (POST)
curl --request POST \
  --url https://api.agntdata.dev/v1/facebook/fetch_search_ads_pages \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "query": "",
  "ad_page_id": "1633779800049051",
  "country": "ALL",
  "activeStatus": "ALL",
  "end_cursor": "",
  "after_time": "",
  "before_time": "",
  "sort_data": ""
}
'
{}

Authorizations

Authorization
string
header
required

Bearer token. Pass your agntdata API key as: Authorization: Bearer agnt_live_...

Body

application/json
query
string
default:""

Search query string

ad_page_id
string
default:1633779800049051

Facebook Ad Page ID. Used only if query is not provided.

country
string
default:ALL

Country filter (e.g. ALL, US, GB)

activeStatus
string
default:ALL

Filter by active status (e.g. ALL, ACTIVE, INACTIVE)

end_cursor
string
default:""

Pagination cursor for next page of results

after_time
string
default:""

Filter ads created after this time

before_time
string
default:""

Filter ads created before this time

sort_data
string
default:""

Sort order for results

Response

Successful response

The response is of type object.