Run a report and return its rows
pinterest_ads_run_reportRequests a Pinterest Ads performance report, polls until it finishes, and returns the rows for analysis. Use it to fetch spend, clicks, and conversion data without changing account data.
Instructions
Request a report, wait for it with progress updates, and return its rows. Same arguments as pinterest_ads_create_report, plus max_rows (default 1000), timeout_seconds (default 600) and poll_seconds (default 10). If it times out the token is returned so you can check later with pinterest_ads_get_report. Changes nothing in the account.
level: ADVERTISER, CAMPAIGN, AD_GROUP, PIN_PROMOTION (ads), KEYWORD, PRODUCT_GROUP, PRODUCT_ITEM, or a *_TARGETING level with targeting_types (up to 5, e.g. ['LOCATION']). Dates are YYYY-MM-DD; granularity TOTAL, DAY, WEEK, MONTH or HOUR. filters adds other request fields, e.g. {"campaign_ids": ["..."], "campaign_statuses": ["RUNNING"]} (campaign_objective_types should include SALES and LEADS, not only the retiring CATALOG_SALES and WEB_CONVERSION). report_format JSON (default) or CSV. To re-run a report saved in Ads Manager, pass template_id (see pinterest_ads_list_report_templates) with dates and granularity only.
Common columns: SPEND_IN_DOLLAR (account currency, despite the name), PAID_IMPRESSION, IMPRESSION_1, CLICKTHROUGH_1 (Pin clicks), OUTBOUND_CLICK_1, CTR, OUTBOUND_CTR_1, CPC_IN_MICRO_DOLLAR, CPM_IN_DOLLAR, TOTAL_ENGAGEMENT, TOTAL_CONVERSIONS, TOTAL_CHECKOUT, TOTAL_CHECKOUT_VALUE_IN_MICRO_DOLLAR, CHECKOUT_ROAS, TOTAL_ADD_TO_CART, TOTAL_LEAD, TOTAL_SIGNUP, CAMPAIGN_NAME, CAMPAIGN_ID. _1 metrics are paid, _2 earned (saves of ads). pinterest_ads_list_metrics lists every column with its definition. HOUR granularity no longer includes conversion metrics.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| level | No | ||
| columns | No | ||
| filters | No | ||
| end_date | Yes | ||
| max_rows | No | ||
| start_date | Yes | ||
| granularity | No | DAY | |
| template_id | No | ||
| poll_seconds | No | ||
| ad_account_id | No | ||
| report_format | No | JSON | |
| targeting_types | No | ||
| timeout_seconds | No | ||
| view_window_days | No | ||
| click_window_days | No | ||
| reporting_timezone | No | ||
| conversion_report_time | No | ||
| engagement_window_days | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||