Your Meta ads' spend, impressions, clicks, conversions
meta-ads.insightsGet spend, impressions, clicks and conversions for your Meta ads
- Price
- freeZum Anbieterpreis
- Success rate
- —Noch keine ErfolgsratendatenNoch keine Erfolgsratendaten
- Latency p50
- ——
- Last verified
- 28.07.2026Verified working
GEThttps://toolswitch.dev/v1/tools/meta-ads.insights?limit=2&date_preset=last_7dPreview- Uses platform quota
- Synchronous response
- Reads public data
Parameter
conversions are NOT top-level fields: they arrive inside `actions` as [{action_type, value}] and you pick the action_type that matches the campaign's objective (purchase, lead, link_click). Attribution defaults to the ad account's setting unless action_attribution_windows is passed. A large request answers with a report_run_id for async polling instead of data
| Parameter | Typ | Erforderlich | Beschreibung | Beispiel |
|---|---|---|---|---|
| Pfadparameter | ||||
object_id | Zeichenkette | Erforderlich | ANY level of the hierarchy: act_… for the whole account, or a campaign / ad set / ad id to scope it down | act_1234567890 |
| Abfrageparameter | ||||
level | Zeichenkette | Optional | account | campaign | adset | ad — the granularity of the ROWS returned, independent of object_id | campaign |
limit | Ganzzahl | Optional | 100 | |
fields | Zeichenkette | Erforderlich | comma-separated metrics | spend,impressions,clicks,ctr,cpc,cpm,reach,frequency,actions,action_values |
breakdowns | Zeichenkette | Optional | e.g. age,gender or publisher_platform — not every breakdown combines with every metric | publisher_platform |
time_range | Zeichenkette | Optional | JSON as a string: {"since":"2026-07-01","until":"2026-07-28"} | |
date_preset | Zeichenkette | Optional | today | yesterday | last_7d | last_14d | last_30d | this_month | maximum — mutually exclusive with time_range | last_30d |
time_increment | Zeichenkette | Optional | 1 for a daily series; omit for one aggregate row | 1 |
- Pfadparameter
object_idZeichenketteErforderlichANY level of the hierarchy: act_… for the whole account, or a campaign / ad set / ad id to scope it down
Beispiel:
act_1234567890- Abfrageparameter
levelZeichenketteOptionalaccount | campaign | adset | ad — the granularity of the ROWS returned, independent of object_id
Beispiel:
campaignlimitGanzzahlOptionalBeispiel:
100fieldsZeichenketteErforderlichcomma-separated metrics
Beispiel:
spend,impressions,clicks,ctr,cpc,cpm,reach,frequency,actions,action_valuesbreakdownsZeichenketteOptionale.g. age,gender or publisher_platform — not every breakdown combines with every metric
Beispiel:
publisher_platformtime_rangeZeichenketteOptionalJSON as a string: {"since":"2026-07-01","until":"2026-07-28"}
date_presetZeichenketteOptionaltoday | yesterday | last_7d | last_14d | last_30d | this_month | maximum — mutually exclusive with time_range
Beispiel:
last_30dtime_incrementZeichenketteOptional1 for a daily series; omit for one aggregate row
Beispiel:
1
Codebeispiele
Ersetze $TOOLSWITCH_KEY durch den in der Konsole erstellten Schlüssel.
curl -X GET 'https://toolswitch.dev/v1/tools/meta-ads.insights?limit=2&date_preset=last_7d' \
-H "X-Toolswitch-Key: $TOOLSWITCH_KEY"import os
import requests
response = requests.request(
"GET",
"https://toolswitch.dev/v1/tools/meta-ads.insights?limit=2&date_preset=last_7d",
headers={"X-Toolswitch-Key": os.environ["TOOLSWITCH_KEY"]},
)
response.raise_for_status()
print(response.text)const response = await fetch("https://toolswitch.dev/v1/tools/meta-ads.insights?limit=2&date_preset=last_7d", {
method: "GET",
headers: {
"X-Toolswitch-Key": process.env.TOOLSWITCH_KEY ?? "",
},
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
console.log(await response.text());Diese Gateway-API ist eine Vorschauversion; URL und Authentifizierung können sich ändern. Die Beispielparameter sind Musterdaten. Aufrufe werden mit free einschließlich Servicegebühr abgerechnet.