Adspirer icon

Adspirer

Manage ad campaigns across Google, Meta, LinkedIn & TikTok Ads via the Adspirer REST API

Actions119

Get Linkedin Engagement Metrics

AI-generated

Summary

Retrieve LinkedIn Ads engagement metrics filtered by specified parameters such as ad account ID, campaign ID or name, and date ranges.

Inputs

  • Platform (required) — The advertising platform to query; must be 'LinkedIn Ads' for this operation.
  • Ad Account Id (required) — The LinkedIn Ad Account ID to fetch metrics for.
  • Campaign Id — Filter metrics to a specific campaign ID.
  • Campaign Name — Filter metrics by campaign name with partial matching.
  • Date Range — Preset date range to retrieve metrics for (e.g., 'last_7_days', 'last_14_days', 'last_30_days', 'last_60_days', 'last_90_days').
  • Start Date — The start date in YYYY-MM-DD format for the metrics data.
  • End Date — The end date in YYYY-MM-DD format for the metrics data.
  • Lookback Days — Number of days to analyze, between 7 and 120. Can be omitted.
  • Raw Data — If true, returns only raw metric data as a JSON code block including spend, clicks, impressions, conversions, CPA, CPC, CTR, CVR, and ROAS by campaign, ad, and date.

Output shape

a JSON object or code block containing LinkedIn engagement metrics aggregated by campaign, ad, and date, or raw JSON metrics if requested.

The output includes campaign-level LinkedIn Ads engagement data filtered by the provided parameters and date range. If the 'Raw Data' option is set to true, the response will be limited to raw metric fields only. Optional filters (campaign ID, campaign name, date range, start/end dates, lookback days) narrow the data scope. Errors are returned if required identifiers (ad account) are missing or invalid.

Examples

Example 1: Get the last 30 days of engagement metrics for a LinkedIn Ad Account without filtering by any specific campaign.

Set Platform to 'LinkedIn Ads', provide a valid Ad Account Id, set Date Range to 'last_30_days'. Leave other campaign and date fields blank.

Example 2: Retrieve raw metrics for a specific LinkedIn campaign filtered by partial campaign name over the last 14 days.

Set Platform to 'LinkedIn Ads', provide Ad Account Id, enter the campaign name (or partial match) to filter, set Date Range to 'last_14_days', and enable 'Raw Data'.

Links

Discussion