@getlatedev/node 0.2.833 → 0.2.834

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -1766,6 +1766,18 @@ type Ad = {
1766
1766
  budget?: {
1767
1767
  amount?: number;
1768
1768
  type?: 'daily' | 'lifetime';
1769
+ /**
1770
+ * LinkedIn only. The parent campaign's `dailyBudget`. LinkedIn allows a daily AND a lifetime budget on the same campaign, which `amount`/`type` cannot express (daily wins there); read `daily` and `lifetime` to see both.
1771
+ */
1772
+ daily?: number;
1773
+ /**
1774
+ * LinkedIn only. The parent campaign's `totalBudget`, readable even when a daily budget is also set.
1775
+ */
1776
+ lifetime?: number;
1777
+ /**
1778
+ * LinkedIn only. The campaign's `pacingStrategy`: how fast LinkedIn may spend the budget. Typically LINEAR or ACCELERATED; the list is open.
1779
+ */
1780
+ pacing?: string;
1769
1781
  } | null;
1770
1782
  metrics?: (AdMetrics | null);
1771
1783
  platformAdId?: string;
@@ -1775,7 +1787,17 @@ type Ad = {
1775
1787
  campaignName?: string;
1776
1788
  adSetName?: string;
1777
1789
  /**
1778
- * Raw Meta campaign objective (e.g. OUTCOME_SALES, OUTCOME_LEADS, OUTCOME_TRAFFIC). Only present for Meta ads.
1790
+ * The platform's own campaign objective, verbatim, alongside the normalized `goal` it maps to.
1791
+ * The mapping is many-to-one, so `goal` alone cannot be mapped back to it.
1792
+ *
1793
+ * - Meta: campaign `objective` (e.g. OUTCOME_SALES, OUTCOME_LEADS, OUTCOME_TRAFFIC).
1794
+ * - LinkedIn: campaign `objectiveType` (e.g. WEBSITE_VISIT, LEAD_GENERATION, BRAND_AWARENESS,
1795
+ * VIDEO_VIEW, ENGAGEMENT, JOB_APPLICANT, WEBSITE_CONVERSION). The list is open, so treat an
1796
+ * unrecognized value as valid rather than an error.
1797
+ * - TikTok and Pinterest: their raw objective_type.
1798
+ *
1799
+ * Null on platforms that report none, and on LinkedIn ads not yet re-synced.
1800
+ *
1779
1801
  */
1780
1802
  platformObjective?: (string) | null;
1781
1803
  /**
@@ -1982,6 +2004,10 @@ type Ad = {
1982
2004
  * LinkedIn only. Whether LinkedIn is currently serving this specific creative. Complements the ad-level `servingStatuses`, which describes the parent campaign.
1983
2005
  */
1984
2006
  isServing?: (boolean) | null;
2007
+ /**
2008
+ * LinkedIn only. The LinkedIn ad format, in LinkedIn's own vocabulary: STANDARD_UPDATE, SINGLE_VIDEO, CAROUSEL, NATIVE_DOCUMENT, EVENT, TEXT_AD, SPOTLIGHT, FOLLOW_COMPANY, JOBS, SPONSORED_INMAILS and others. On an ad Zernio created this is the format it was created as; on an ad synced from Campaign Manager it is the parent campaign's raw `format`, which is what LinkedIn actually enforces on its creatives. The list is open, so treat an unrecognized value as valid. Absent on LinkedIn ads not yet re-synced, and on every other platform.
2009
+ */
2010
+ adFormat?: (string) | null;
1985
2011
  /**
1986
2012
  * LinkedIn only. Why this specific creative is not being served. Empty when it is serving.
1987
2013
  * A superset of the ad-level `servingStatuses`: it repeats the inherited campaign, campaign
@@ -2068,6 +2094,24 @@ type AdAnalyticsResponse = {
2068
2094
  daily?: Array<(AdMetrics & {
2069
2095
  date?: string;
2070
2096
  })>;
2097
+ /**
2098
+ * Requested demographic breakdowns, keyed by dimension. Fetched live from the
2099
+ * platform per request and never stored, so these rows can carry fields the
2100
+ * stored `summary` and `daily` series do not.
2101
+ *
2102
+ * LinkedIn rows carry `value` (the pivot URN), `name` (resolved label where
2103
+ * LinkedIn provides one), the usual spend/impressions/clicks/ctr/cpc/cpm/engagement
2104
+ * figures, plus two reach fields:
2105
+ *
2106
+ * - `reach`: the segment's `approximateMemberReach`.
2107
+ * - `audiencePenetration`: LinkedIn's own ratio of members reached to the size of
2108
+ * the targeted audience, passed through verbatim.
2109
+ *
2110
+ * LinkedIn withholds both below its audience privacy threshold, in which case the
2111
+ * keys are ABSENT rather than 0. `audiencePenetration` is available here only: it
2112
+ * is not part of the stored metrics series.
2113
+ *
2114
+ */
2071
2115
  breakdowns?: {
2072
2116
  [key: string]: Array<{
2073
2117
  [key: string]: unknown;
@@ -2255,7 +2299,7 @@ type AdEngagementCounts = {
2255
2299
  */
2256
2300
  pageLikes?: number;
2257
2301
  /**
2258
- * 3-second video views (`video_view`). For completion-based counts use `videoThruplayWatchedActions`.
2302
+ * Video views, from the `video_view` action. Meta counts a 3-second view; LinkedIn's own `videoViews` threshold (2 continuous seconds, or 25% of the video) lands under the same key, so compare across platforms with care. For completion-based counts use `videoThruplayWatchedActions`.
2259
2303
  */
2260
2304
  videoViews?: number;
2261
2305
  /**
@@ -2432,7 +2476,7 @@ type AdMetrics = {
2432
2476
  spend?: number;
2433
2477
  impressions?: number;
2434
2478
  /**
2435
- * Unique people reached in the requested date range. Meta (facebook/instagram) and TikTok: the platform's own de-duplicated reach for the exact range, fetched live and cached up to ~1 hour (may lag recent delivery; on a transient platform error the value temporarily falls back to a sum of per-day reach, which overcounts people reached on multiple days or by multiple child ads). Because it is de-duplicated, reach is NOT additive on these platforms: neither daily values nor child nodes sum to the range total. Google, LinkedIn, X, Pinterest and OpenAI report 0 (reach not synced). Frequency (impressions / reach) is only meaningful for Meta and TikTok.
2479
+ * Unique people reached in the requested date range. Meta (facebook/instagram) and TikTok: the platform's own de-duplicated reach for the exact range, fetched live and cached up to ~1 hour (may lag recent delivery; on a transient platform error the value temporarily falls back to a sum of per-day reach, which overcounts people reached on multiple days or by multiple child ads). Because it is de-duplicated, reach is NOT additive on these platforms: neither daily values nor child nodes sum to the range total. LinkedIn: the campaign's `approximateMemberReach`, de-duplicated by LinkedIn per day and then summed over the range here, so it overcounts members reached on more than one day; LinkedIn withholds it below its audience privacy threshold, where it reads 0. Google, X, Pinterest and OpenAI report 0 (reach not synced). Frequency (impressions / reach) is only meaningful for Meta and TikTok.
2436
2480
  */
2437
2481
  reach?: number;
2438
2482
  clicks?: number;
@@ -2462,7 +2506,7 @@ type AdMetrics = {
2462
2506
  */
2463
2507
  costPerConversion?: number;
2464
2508
  /**
2465
- * Per-action-type counts summed over the date range, keyed by the platform's action-type names. Meta: raw Insights action_type keys (link_click, offsite_conversion.fb_pixel_purchase, onsite_conversion.lead_grouped, ...), covering both engagement and conversion events. TikTok: pixel conversions (purchase, add_to_cart, initiate_checkout, view_content, complete_payment, lead) plus the paid-engagement family (follow, post_reaction for paid likes, comment, share). Follow is how FOLLOWERS-goal campaigns report their result. X: conversion types (purchase, sign_up, site_visit, download, custom). LinkedIn: conversion types (post_click, post_view, lead_gen). Google returns {} (its per-action names aren't synced per ad). Empty object when no actions are reported. NOTE: keys differ by platform, so branch on the ad's platform when interpreting them.
2509
+ * Per-action-type counts summed over the date range, keyed by the platform's action-type names. Meta: raw Insights action_type keys (link_click, offsite_conversion.fb_pixel_purchase, onsite_conversion.lead_grouped, ...), covering both engagement and conversion events. TikTok: pixel conversions (purchase, add_to_cart, initiate_checkout, view_content, complete_payment, lead) plus the paid-engagement family (follow, post_reaction for paid likes, comment, share). Follow is how FOLLOWERS-goal campaigns report their result. X: conversion types (purchase, sign_up, site_visit, download, custom). LinkedIn: conversion types (post_click, post_view, lead_gen) plus `video_view`, which carries LinkedIn's `videoViews` under the same key every other platform uses, so it feeds `engagementBreakdown.videoViews` too; it is an engagement, NOT a conversion, and is excluded from `conversions`. Google returns {} (its per-action names aren't synced per ad). Empty object when no actions are reported. NOTE: keys differ by platform, so branch on the ad's platform when interpreting them.
2466
2510
  */
2467
2511
  actions?: {
2468
2512
  [key: string]: (number);
@@ -2845,6 +2889,18 @@ type AdTreeAdSet = {
2845
2889
  budget?: {
2846
2890
  amount?: number;
2847
2891
  type?: 'daily' | 'lifetime';
2892
+ /**
2893
+ * LinkedIn only. The campaign's `dailyBudget`. LinkedIn allows a daily AND a lifetime budget on the same campaign, which `amount`/`type` cannot express (daily wins there); read `daily` and `lifetime` to see both.
2894
+ */
2895
+ daily?: number;
2896
+ /**
2897
+ * LinkedIn only. The campaign's `totalBudget`, readable even when a daily budget is also set.
2898
+ */
2899
+ lifetime?: number;
2900
+ /**
2901
+ * LinkedIn only. The campaign's `pacingStrategy`: how fast LinkedIn may spend the budget. Typically LINEAR or ACCELERATED; the list is open.
2902
+ */
2903
+ pacing?: string;
2848
2904
  } | null;
2849
2905
  /**
2850
2906
  * Ad-set-level budget (ABO). Null for CBO campaigns where the budget is set on the campaign.
@@ -2852,6 +2908,18 @@ type AdTreeAdSet = {
2852
2908
  adSetBudget?: {
2853
2909
  amount?: number;
2854
2910
  type?: 'daily' | 'lifetime';
2911
+ /**
2912
+ * LinkedIn only. See `budget.daily`.
2913
+ */
2914
+ daily?: number;
2915
+ /**
2916
+ * LinkedIn only. See `budget.lifetime`.
2917
+ */
2918
+ lifetime?: number;
2919
+ /**
2920
+ * LinkedIn only. See `budget.pacing`.
2921
+ */
2922
+ pacing?: string;
2855
2923
  } | null;
2856
2924
  metrics?: AdMetrics;
2857
2925
  /**
@@ -4142,6 +4210,24 @@ type CampaignAnalyticsResponse = {
4142
4210
  daily?: Array<(AdMetrics & {
4143
4211
  date?: string;
4144
4212
  })>;
4213
+ /**
4214
+ * Requested demographic breakdowns, keyed by dimension. Fetched live from the
4215
+ * platform per request and never stored, so these rows can carry fields the
4216
+ * stored `summary` and `daily` series do not.
4217
+ *
4218
+ * LinkedIn rows carry `value` (the pivot URN), `name` (resolved label where
4219
+ * LinkedIn provides one), the usual spend/impressions/clicks/ctr/cpc/cpm/engagement
4220
+ * figures, plus two reach fields:
4221
+ *
4222
+ * - `reach`: the segment's `approximateMemberReach`.
4223
+ * - `audiencePenetration`: LinkedIn's own ratio of members reached to the size of
4224
+ * the targeted audience, passed through verbatim.
4225
+ *
4226
+ * LinkedIn withholds both below its audience privacy threshold, in which case the
4227
+ * keys are ABSENT rather than 0. `audiencePenetration` is available here only: it
4228
+ * is not part of the stored metrics series.
4229
+ *
4230
+ */
4145
4231
  breakdowns?: {
4146
4232
  [key: string]: Array<{
4147
4233
  [key: string]: unknown;
@@ -34391,7 +34477,61 @@ type ListAdSetsResponse = ({
34391
34477
  profileId?: string;
34392
34478
  currency?: (string) | null;
34393
34479
  budget?: {
34394
- [key: string]: unknown;
34480
+ amount?: number;
34481
+ type?: 'daily' | 'lifetime';
34482
+ /**
34483
+ * LinkedIn only. The campaign's `dailyBudget`. LinkedIn allows a daily AND a lifetime budget on the same campaign, which `amount`/`type` cannot express (daily wins there); read `daily` and `lifetime` to see both.
34484
+ */
34485
+ daily?: number;
34486
+ /**
34487
+ * LinkedIn only. The campaign's `totalBudget`, readable even when a daily budget is also set.
34488
+ */
34489
+ lifetime?: number;
34490
+ /**
34491
+ * LinkedIn only. The campaign's `pacingStrategy`: how fast LinkedIn may spend the budget. Typically LINEAR or ACCELERATED; the list is open.
34492
+ */
34493
+ pacing?: string;
34494
+ } | null;
34495
+ /**
34496
+ * The ad set's own flight dates, as synced from the platform. On LinkedIn this is the campaign's `runSchedule`. Null when the platform reports none.
34497
+ */
34498
+ schedule?: {
34499
+ startDate?: string;
34500
+ /**
34501
+ * Absent when the ad set runs until it is stopped.
34502
+ */
34503
+ endDate?: string;
34504
+ } | null;
34505
+ /**
34506
+ * The audience this ad set delivers to, as the platform reports it. LinkedIn only
34507
+ * today; null for every other platform and for LinkedIn ad sets not yet re-synced.
34508
+ *
34509
+ * `include` and `exclude` are the campaign's `targetingCriteria` verbatim, so they
34510
+ * can be read, edited and sent back without reconstructing them from our normalized
34511
+ * targeting spec. Exclusions were previously not readable at all.
34512
+ *
34513
+ */
34514
+ targeting?: {
34515
+ /**
34516
+ * LinkedIn `targetingCriteria.include`, verbatim (an `and` of `or` facet clauses).
34517
+ */
34518
+ include?: {
34519
+ [key: string]: unknown;
34520
+ };
34521
+ /**
34522
+ * LinkedIn `targetingCriteria.exclude`, verbatim. Absent when the campaign excludes nothing.
34523
+ */
34524
+ exclude?: {
34525
+ [key: string]: unknown;
34526
+ };
34527
+ /**
34528
+ * LinkedIn audience expansion: whether LinkedIn may also serve to members similar to the criteria.
34529
+ */
34530
+ audienceExpansionEnabled?: boolean;
34531
+ /**
34532
+ * Whether the campaign may deliver on the LinkedIn Audience Network, off LinkedIn itself.
34533
+ */
34534
+ offsiteDeliveryEnabled?: boolean;
34395
34535
  } | null;
34396
34536
  isExternal?: (boolean) | null;
34397
34537
  platformCreatedAt?: (string) | null;
@@ -40233,6 +40373,10 @@ type EstimateAdReachResponse = ({
40233
40373
  * Optional estimated daily reach/results at the given budget, when the platform returns it.
40234
40374
  */
40235
40375
  daily?: (number) | null;
40376
+ /**
40377
+ * LinkedIn only. LinkedIn's `audienceCounts.active`, verbatim: the active subset of the same audience `lower`/`upper` carry as its `total`. Absent when LinkedIn does not report it; `0` is a real answer, not a missing one.
40378
+ */
40379
+ active?: (number) | null;
40236
40380
  /**
40237
40381
  * Currency of any monetary fields in the estimate, when applicable.
40238
40382
  */
package/dist/index.d.ts CHANGED
@@ -1766,6 +1766,18 @@ type Ad = {
1766
1766
  budget?: {
1767
1767
  amount?: number;
1768
1768
  type?: 'daily' | 'lifetime';
1769
+ /**
1770
+ * LinkedIn only. The parent campaign's `dailyBudget`. LinkedIn allows a daily AND a lifetime budget on the same campaign, which `amount`/`type` cannot express (daily wins there); read `daily` and `lifetime` to see both.
1771
+ */
1772
+ daily?: number;
1773
+ /**
1774
+ * LinkedIn only. The parent campaign's `totalBudget`, readable even when a daily budget is also set.
1775
+ */
1776
+ lifetime?: number;
1777
+ /**
1778
+ * LinkedIn only. The campaign's `pacingStrategy`: how fast LinkedIn may spend the budget. Typically LINEAR or ACCELERATED; the list is open.
1779
+ */
1780
+ pacing?: string;
1769
1781
  } | null;
1770
1782
  metrics?: (AdMetrics | null);
1771
1783
  platformAdId?: string;
@@ -1775,7 +1787,17 @@ type Ad = {
1775
1787
  campaignName?: string;
1776
1788
  adSetName?: string;
1777
1789
  /**
1778
- * Raw Meta campaign objective (e.g. OUTCOME_SALES, OUTCOME_LEADS, OUTCOME_TRAFFIC). Only present for Meta ads.
1790
+ * The platform's own campaign objective, verbatim, alongside the normalized `goal` it maps to.
1791
+ * The mapping is many-to-one, so `goal` alone cannot be mapped back to it.
1792
+ *
1793
+ * - Meta: campaign `objective` (e.g. OUTCOME_SALES, OUTCOME_LEADS, OUTCOME_TRAFFIC).
1794
+ * - LinkedIn: campaign `objectiveType` (e.g. WEBSITE_VISIT, LEAD_GENERATION, BRAND_AWARENESS,
1795
+ * VIDEO_VIEW, ENGAGEMENT, JOB_APPLICANT, WEBSITE_CONVERSION). The list is open, so treat an
1796
+ * unrecognized value as valid rather than an error.
1797
+ * - TikTok and Pinterest: their raw objective_type.
1798
+ *
1799
+ * Null on platforms that report none, and on LinkedIn ads not yet re-synced.
1800
+ *
1779
1801
  */
1780
1802
  platformObjective?: (string) | null;
1781
1803
  /**
@@ -1982,6 +2004,10 @@ type Ad = {
1982
2004
  * LinkedIn only. Whether LinkedIn is currently serving this specific creative. Complements the ad-level `servingStatuses`, which describes the parent campaign.
1983
2005
  */
1984
2006
  isServing?: (boolean) | null;
2007
+ /**
2008
+ * LinkedIn only. The LinkedIn ad format, in LinkedIn's own vocabulary: STANDARD_UPDATE, SINGLE_VIDEO, CAROUSEL, NATIVE_DOCUMENT, EVENT, TEXT_AD, SPOTLIGHT, FOLLOW_COMPANY, JOBS, SPONSORED_INMAILS and others. On an ad Zernio created this is the format it was created as; on an ad synced from Campaign Manager it is the parent campaign's raw `format`, which is what LinkedIn actually enforces on its creatives. The list is open, so treat an unrecognized value as valid. Absent on LinkedIn ads not yet re-synced, and on every other platform.
2009
+ */
2010
+ adFormat?: (string) | null;
1985
2011
  /**
1986
2012
  * LinkedIn only. Why this specific creative is not being served. Empty when it is serving.
1987
2013
  * A superset of the ad-level `servingStatuses`: it repeats the inherited campaign, campaign
@@ -2068,6 +2094,24 @@ type AdAnalyticsResponse = {
2068
2094
  daily?: Array<(AdMetrics & {
2069
2095
  date?: string;
2070
2096
  })>;
2097
+ /**
2098
+ * Requested demographic breakdowns, keyed by dimension. Fetched live from the
2099
+ * platform per request and never stored, so these rows can carry fields the
2100
+ * stored `summary` and `daily` series do not.
2101
+ *
2102
+ * LinkedIn rows carry `value` (the pivot URN), `name` (resolved label where
2103
+ * LinkedIn provides one), the usual spend/impressions/clicks/ctr/cpc/cpm/engagement
2104
+ * figures, plus two reach fields:
2105
+ *
2106
+ * - `reach`: the segment's `approximateMemberReach`.
2107
+ * - `audiencePenetration`: LinkedIn's own ratio of members reached to the size of
2108
+ * the targeted audience, passed through verbatim.
2109
+ *
2110
+ * LinkedIn withholds both below its audience privacy threshold, in which case the
2111
+ * keys are ABSENT rather than 0. `audiencePenetration` is available here only: it
2112
+ * is not part of the stored metrics series.
2113
+ *
2114
+ */
2071
2115
  breakdowns?: {
2072
2116
  [key: string]: Array<{
2073
2117
  [key: string]: unknown;
@@ -2255,7 +2299,7 @@ type AdEngagementCounts = {
2255
2299
  */
2256
2300
  pageLikes?: number;
2257
2301
  /**
2258
- * 3-second video views (`video_view`). For completion-based counts use `videoThruplayWatchedActions`.
2302
+ * Video views, from the `video_view` action. Meta counts a 3-second view; LinkedIn's own `videoViews` threshold (2 continuous seconds, or 25% of the video) lands under the same key, so compare across platforms with care. For completion-based counts use `videoThruplayWatchedActions`.
2259
2303
  */
2260
2304
  videoViews?: number;
2261
2305
  /**
@@ -2432,7 +2476,7 @@ type AdMetrics = {
2432
2476
  spend?: number;
2433
2477
  impressions?: number;
2434
2478
  /**
2435
- * Unique people reached in the requested date range. Meta (facebook/instagram) and TikTok: the platform's own de-duplicated reach for the exact range, fetched live and cached up to ~1 hour (may lag recent delivery; on a transient platform error the value temporarily falls back to a sum of per-day reach, which overcounts people reached on multiple days or by multiple child ads). Because it is de-duplicated, reach is NOT additive on these platforms: neither daily values nor child nodes sum to the range total. Google, LinkedIn, X, Pinterest and OpenAI report 0 (reach not synced). Frequency (impressions / reach) is only meaningful for Meta and TikTok.
2479
+ * Unique people reached in the requested date range. Meta (facebook/instagram) and TikTok: the platform's own de-duplicated reach for the exact range, fetched live and cached up to ~1 hour (may lag recent delivery; on a transient platform error the value temporarily falls back to a sum of per-day reach, which overcounts people reached on multiple days or by multiple child ads). Because it is de-duplicated, reach is NOT additive on these platforms: neither daily values nor child nodes sum to the range total. LinkedIn: the campaign's `approximateMemberReach`, de-duplicated by LinkedIn per day and then summed over the range here, so it overcounts members reached on more than one day; LinkedIn withholds it below its audience privacy threshold, where it reads 0. Google, X, Pinterest and OpenAI report 0 (reach not synced). Frequency (impressions / reach) is only meaningful for Meta and TikTok.
2436
2480
  */
2437
2481
  reach?: number;
2438
2482
  clicks?: number;
@@ -2462,7 +2506,7 @@ type AdMetrics = {
2462
2506
  */
2463
2507
  costPerConversion?: number;
2464
2508
  /**
2465
- * Per-action-type counts summed over the date range, keyed by the platform's action-type names. Meta: raw Insights action_type keys (link_click, offsite_conversion.fb_pixel_purchase, onsite_conversion.lead_grouped, ...), covering both engagement and conversion events. TikTok: pixel conversions (purchase, add_to_cart, initiate_checkout, view_content, complete_payment, lead) plus the paid-engagement family (follow, post_reaction for paid likes, comment, share). Follow is how FOLLOWERS-goal campaigns report their result. X: conversion types (purchase, sign_up, site_visit, download, custom). LinkedIn: conversion types (post_click, post_view, lead_gen). Google returns {} (its per-action names aren't synced per ad). Empty object when no actions are reported. NOTE: keys differ by platform, so branch on the ad's platform when interpreting them.
2509
+ * Per-action-type counts summed over the date range, keyed by the platform's action-type names. Meta: raw Insights action_type keys (link_click, offsite_conversion.fb_pixel_purchase, onsite_conversion.lead_grouped, ...), covering both engagement and conversion events. TikTok: pixel conversions (purchase, add_to_cart, initiate_checkout, view_content, complete_payment, lead) plus the paid-engagement family (follow, post_reaction for paid likes, comment, share). Follow is how FOLLOWERS-goal campaigns report their result. X: conversion types (purchase, sign_up, site_visit, download, custom). LinkedIn: conversion types (post_click, post_view, lead_gen) plus `video_view`, which carries LinkedIn's `videoViews` under the same key every other platform uses, so it feeds `engagementBreakdown.videoViews` too; it is an engagement, NOT a conversion, and is excluded from `conversions`. Google returns {} (its per-action names aren't synced per ad). Empty object when no actions are reported. NOTE: keys differ by platform, so branch on the ad's platform when interpreting them.
2466
2510
  */
2467
2511
  actions?: {
2468
2512
  [key: string]: (number);
@@ -2845,6 +2889,18 @@ type AdTreeAdSet = {
2845
2889
  budget?: {
2846
2890
  amount?: number;
2847
2891
  type?: 'daily' | 'lifetime';
2892
+ /**
2893
+ * LinkedIn only. The campaign's `dailyBudget`. LinkedIn allows a daily AND a lifetime budget on the same campaign, which `amount`/`type` cannot express (daily wins there); read `daily` and `lifetime` to see both.
2894
+ */
2895
+ daily?: number;
2896
+ /**
2897
+ * LinkedIn only. The campaign's `totalBudget`, readable even when a daily budget is also set.
2898
+ */
2899
+ lifetime?: number;
2900
+ /**
2901
+ * LinkedIn only. The campaign's `pacingStrategy`: how fast LinkedIn may spend the budget. Typically LINEAR or ACCELERATED; the list is open.
2902
+ */
2903
+ pacing?: string;
2848
2904
  } | null;
2849
2905
  /**
2850
2906
  * Ad-set-level budget (ABO). Null for CBO campaigns where the budget is set on the campaign.
@@ -2852,6 +2908,18 @@ type AdTreeAdSet = {
2852
2908
  adSetBudget?: {
2853
2909
  amount?: number;
2854
2910
  type?: 'daily' | 'lifetime';
2911
+ /**
2912
+ * LinkedIn only. See `budget.daily`.
2913
+ */
2914
+ daily?: number;
2915
+ /**
2916
+ * LinkedIn only. See `budget.lifetime`.
2917
+ */
2918
+ lifetime?: number;
2919
+ /**
2920
+ * LinkedIn only. See `budget.pacing`.
2921
+ */
2922
+ pacing?: string;
2855
2923
  } | null;
2856
2924
  metrics?: AdMetrics;
2857
2925
  /**
@@ -4142,6 +4210,24 @@ type CampaignAnalyticsResponse = {
4142
4210
  daily?: Array<(AdMetrics & {
4143
4211
  date?: string;
4144
4212
  })>;
4213
+ /**
4214
+ * Requested demographic breakdowns, keyed by dimension. Fetched live from the
4215
+ * platform per request and never stored, so these rows can carry fields the
4216
+ * stored `summary` and `daily` series do not.
4217
+ *
4218
+ * LinkedIn rows carry `value` (the pivot URN), `name` (resolved label where
4219
+ * LinkedIn provides one), the usual spend/impressions/clicks/ctr/cpc/cpm/engagement
4220
+ * figures, plus two reach fields:
4221
+ *
4222
+ * - `reach`: the segment's `approximateMemberReach`.
4223
+ * - `audiencePenetration`: LinkedIn's own ratio of members reached to the size of
4224
+ * the targeted audience, passed through verbatim.
4225
+ *
4226
+ * LinkedIn withholds both below its audience privacy threshold, in which case the
4227
+ * keys are ABSENT rather than 0. `audiencePenetration` is available here only: it
4228
+ * is not part of the stored metrics series.
4229
+ *
4230
+ */
4145
4231
  breakdowns?: {
4146
4232
  [key: string]: Array<{
4147
4233
  [key: string]: unknown;
@@ -34391,7 +34477,61 @@ type ListAdSetsResponse = ({
34391
34477
  profileId?: string;
34392
34478
  currency?: (string) | null;
34393
34479
  budget?: {
34394
- [key: string]: unknown;
34480
+ amount?: number;
34481
+ type?: 'daily' | 'lifetime';
34482
+ /**
34483
+ * LinkedIn only. The campaign's `dailyBudget`. LinkedIn allows a daily AND a lifetime budget on the same campaign, which `amount`/`type` cannot express (daily wins there); read `daily` and `lifetime` to see both.
34484
+ */
34485
+ daily?: number;
34486
+ /**
34487
+ * LinkedIn only. The campaign's `totalBudget`, readable even when a daily budget is also set.
34488
+ */
34489
+ lifetime?: number;
34490
+ /**
34491
+ * LinkedIn only. The campaign's `pacingStrategy`: how fast LinkedIn may spend the budget. Typically LINEAR or ACCELERATED; the list is open.
34492
+ */
34493
+ pacing?: string;
34494
+ } | null;
34495
+ /**
34496
+ * The ad set's own flight dates, as synced from the platform. On LinkedIn this is the campaign's `runSchedule`. Null when the platform reports none.
34497
+ */
34498
+ schedule?: {
34499
+ startDate?: string;
34500
+ /**
34501
+ * Absent when the ad set runs until it is stopped.
34502
+ */
34503
+ endDate?: string;
34504
+ } | null;
34505
+ /**
34506
+ * The audience this ad set delivers to, as the platform reports it. LinkedIn only
34507
+ * today; null for every other platform and for LinkedIn ad sets not yet re-synced.
34508
+ *
34509
+ * `include` and `exclude` are the campaign's `targetingCriteria` verbatim, so they
34510
+ * can be read, edited and sent back without reconstructing them from our normalized
34511
+ * targeting spec. Exclusions were previously not readable at all.
34512
+ *
34513
+ */
34514
+ targeting?: {
34515
+ /**
34516
+ * LinkedIn `targetingCriteria.include`, verbatim (an `and` of `or` facet clauses).
34517
+ */
34518
+ include?: {
34519
+ [key: string]: unknown;
34520
+ };
34521
+ /**
34522
+ * LinkedIn `targetingCriteria.exclude`, verbatim. Absent when the campaign excludes nothing.
34523
+ */
34524
+ exclude?: {
34525
+ [key: string]: unknown;
34526
+ };
34527
+ /**
34528
+ * LinkedIn audience expansion: whether LinkedIn may also serve to members similar to the criteria.
34529
+ */
34530
+ audienceExpansionEnabled?: boolean;
34531
+ /**
34532
+ * Whether the campaign may deliver on the LinkedIn Audience Network, off LinkedIn itself.
34533
+ */
34534
+ offsiteDeliveryEnabled?: boolean;
34395
34535
  } | null;
34396
34536
  isExternal?: (boolean) | null;
34397
34537
  platformCreatedAt?: (string) | null;
@@ -40233,6 +40373,10 @@ type EstimateAdReachResponse = ({
40233
40373
  * Optional estimated daily reach/results at the given budget, when the platform returns it.
40234
40374
  */
40235
40375
  daily?: (number) | null;
40376
+ /**
40377
+ * LinkedIn only. LinkedIn's `audienceCounts.active`, verbatim: the active subset of the same audience `lower`/`upper` carry as its `total`. Absent when LinkedIn does not report it; `0` is a real answer, not a missing one.
40378
+ */
40379
+ active?: (number) | null;
40236
40380
  /**
40237
40381
  * Currency of any monetary fields in the estimate, when applicable.
40238
40382
  */
package/dist/index.js CHANGED
@@ -36,7 +36,7 @@ module.exports = __toCommonJS(index_exports);
36
36
  // package.json
37
37
  var package_default = {
38
38
  name: "@getlatedev/node",
39
- version: "0.2.833",
39
+ version: "0.2.834",
40
40
  description: "The official Node.js library for the Zernio API",
41
41
  main: "dist/index.js",
42
42
  module: "dist/index.mjs",
package/dist/index.mjs CHANGED
@@ -5,7 +5,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
5
5
  // package.json
6
6
  var package_default = {
7
7
  name: "@getlatedev/node",
8
- version: "0.2.833",
8
+ version: "0.2.834",
9
9
  description: "The official Node.js library for the Zernio API",
10
10
  main: "dist/index.js",
11
11
  module: "dist/index.mjs",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@getlatedev/node",
3
- "version": "0.2.833",
3
+ "version": "0.2.834",
4
4
  "description": "The official Node.js library for the Zernio API",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -115,6 +115,18 @@ export type Ad = {
115
115
  budget?: {
116
116
  amount?: number;
117
117
  type?: 'daily' | 'lifetime';
118
+ /**
119
+ * LinkedIn only. The parent campaign's `dailyBudget`. LinkedIn allows a daily AND a lifetime budget on the same campaign, which `amount`/`type` cannot express (daily wins there); read `daily` and `lifetime` to see both.
120
+ */
121
+ daily?: number;
122
+ /**
123
+ * LinkedIn only. The parent campaign's `totalBudget`, readable even when a daily budget is also set.
124
+ */
125
+ lifetime?: number;
126
+ /**
127
+ * LinkedIn only. The campaign's `pacingStrategy`: how fast LinkedIn may spend the budget. Typically LINEAR or ACCELERATED; the list is open.
128
+ */
129
+ pacing?: string;
118
130
  } | null;
119
131
  metrics?: (AdMetrics | null);
120
132
  platformAdId?: string;
@@ -124,7 +136,17 @@ export type Ad = {
124
136
  campaignName?: string;
125
137
  adSetName?: string;
126
138
  /**
127
- * Raw Meta campaign objective (e.g. OUTCOME_SALES, OUTCOME_LEADS, OUTCOME_TRAFFIC). Only present for Meta ads.
139
+ * The platform's own campaign objective, verbatim, alongside the normalized `goal` it maps to.
140
+ * The mapping is many-to-one, so `goal` alone cannot be mapped back to it.
141
+ *
142
+ * - Meta: campaign `objective` (e.g. OUTCOME_SALES, OUTCOME_LEADS, OUTCOME_TRAFFIC).
143
+ * - LinkedIn: campaign `objectiveType` (e.g. WEBSITE_VISIT, LEAD_GENERATION, BRAND_AWARENESS,
144
+ * VIDEO_VIEW, ENGAGEMENT, JOB_APPLICANT, WEBSITE_CONVERSION). The list is open, so treat an
145
+ * unrecognized value as valid rather than an error.
146
+ * - TikTok and Pinterest: their raw objective_type.
147
+ *
148
+ * Null on platforms that report none, and on LinkedIn ads not yet re-synced.
149
+ *
128
150
  */
129
151
  platformObjective?: (string) | null;
130
152
  /**
@@ -331,6 +353,10 @@ export type Ad = {
331
353
  * LinkedIn only. Whether LinkedIn is currently serving this specific creative. Complements the ad-level `servingStatuses`, which describes the parent campaign.
332
354
  */
333
355
  isServing?: (boolean) | null;
356
+ /**
357
+ * LinkedIn only. The LinkedIn ad format, in LinkedIn's own vocabulary: STANDARD_UPDATE, SINGLE_VIDEO, CAROUSEL, NATIVE_DOCUMENT, EVENT, TEXT_AD, SPOTLIGHT, FOLLOW_COMPANY, JOBS, SPONSORED_INMAILS and others. On an ad Zernio created this is the format it was created as; on an ad synced from Campaign Manager it is the parent campaign's raw `format`, which is what LinkedIn actually enforces on its creatives. The list is open, so treat an unrecognized value as valid. Absent on LinkedIn ads not yet re-synced, and on every other platform.
358
+ */
359
+ adFormat?: (string) | null;
334
360
  /**
335
361
  * LinkedIn only. Why this specific creative is not being served. Empty when it is serving.
336
362
  * A superset of the ad-level `servingStatuses`: it repeats the inherited campaign, campaign
@@ -423,6 +449,24 @@ export type AdAnalyticsResponse = {
423
449
  daily?: Array<(AdMetrics & {
424
450
  date?: string;
425
451
  })>;
452
+ /**
453
+ * Requested demographic breakdowns, keyed by dimension. Fetched live from the
454
+ * platform per request and never stored, so these rows can carry fields the
455
+ * stored `summary` and `daily` series do not.
456
+ *
457
+ * LinkedIn rows carry `value` (the pivot URN), `name` (resolved label where
458
+ * LinkedIn provides one), the usual spend/impressions/clicks/ctr/cpc/cpm/engagement
459
+ * figures, plus two reach fields:
460
+ *
461
+ * - `reach`: the segment's `approximateMemberReach`.
462
+ * - `audiencePenetration`: LinkedIn's own ratio of members reached to the size of
463
+ * the targeted audience, passed through verbatim.
464
+ *
465
+ * LinkedIn withholds both below its audience privacy threshold, in which case the
466
+ * keys are ABSENT rather than 0. `audiencePenetration` is available here only: it
467
+ * is not part of the stored metrics series.
468
+ *
469
+ */
426
470
  breakdowns?: {
427
471
  [key: string]: Array<{
428
472
  [key: string]: unknown;
@@ -616,7 +660,7 @@ export type AdEngagementCounts = {
616
660
  */
617
661
  pageLikes?: number;
618
662
  /**
619
- * 3-second video views (`video_view`). For completion-based counts use `videoThruplayWatchedActions`.
663
+ * Video views, from the `video_view` action. Meta counts a 3-second view; LinkedIn's own `videoViews` threshold (2 continuous seconds, or 25% of the video) lands under the same key, so compare across platforms with care. For completion-based counts use `videoThruplayWatchedActions`.
620
664
  */
621
665
  videoViews?: number;
622
666
  /**
@@ -802,7 +846,7 @@ export type AdMetrics = {
802
846
  spend?: number;
803
847
  impressions?: number;
804
848
  /**
805
- * Unique people reached in the requested date range. Meta (facebook/instagram) and TikTok: the platform's own de-duplicated reach for the exact range, fetched live and cached up to ~1 hour (may lag recent delivery; on a transient platform error the value temporarily falls back to a sum of per-day reach, which overcounts people reached on multiple days or by multiple child ads). Because it is de-duplicated, reach is NOT additive on these platforms: neither daily values nor child nodes sum to the range total. Google, LinkedIn, X, Pinterest and OpenAI report 0 (reach not synced). Frequency (impressions / reach) is only meaningful for Meta and TikTok.
849
+ * Unique people reached in the requested date range. Meta (facebook/instagram) and TikTok: the platform's own de-duplicated reach for the exact range, fetched live and cached up to ~1 hour (may lag recent delivery; on a transient platform error the value temporarily falls back to a sum of per-day reach, which overcounts people reached on multiple days or by multiple child ads). Because it is de-duplicated, reach is NOT additive on these platforms: neither daily values nor child nodes sum to the range total. LinkedIn: the campaign's `approximateMemberReach`, de-duplicated by LinkedIn per day and then summed over the range here, so it overcounts members reached on more than one day; LinkedIn withholds it below its audience privacy threshold, where it reads 0. Google, X, Pinterest and OpenAI report 0 (reach not synced). Frequency (impressions / reach) is only meaningful for Meta and TikTok.
806
850
  */
807
851
  reach?: number;
808
852
  clicks?: number;
@@ -832,7 +876,7 @@ export type AdMetrics = {
832
876
  */
833
877
  costPerConversion?: number;
834
878
  /**
835
- * Per-action-type counts summed over the date range, keyed by the platform's action-type names. Meta: raw Insights action_type keys (link_click, offsite_conversion.fb_pixel_purchase, onsite_conversion.lead_grouped, ...), covering both engagement and conversion events. TikTok: pixel conversions (purchase, add_to_cart, initiate_checkout, view_content, complete_payment, lead) plus the paid-engagement family (follow, post_reaction for paid likes, comment, share). Follow is how FOLLOWERS-goal campaigns report their result. X: conversion types (purchase, sign_up, site_visit, download, custom). LinkedIn: conversion types (post_click, post_view, lead_gen). Google returns {} (its per-action names aren't synced per ad). Empty object when no actions are reported. NOTE: keys differ by platform, so branch on the ad's platform when interpreting them.
879
+ * Per-action-type counts summed over the date range, keyed by the platform's action-type names. Meta: raw Insights action_type keys (link_click, offsite_conversion.fb_pixel_purchase, onsite_conversion.lead_grouped, ...), covering both engagement and conversion events. TikTok: pixel conversions (purchase, add_to_cart, initiate_checkout, view_content, complete_payment, lead) plus the paid-engagement family (follow, post_reaction for paid likes, comment, share). Follow is how FOLLOWERS-goal campaigns report their result. X: conversion types (purchase, sign_up, site_visit, download, custom). LinkedIn: conversion types (post_click, post_view, lead_gen) plus `video_view`, which carries LinkedIn's `videoViews` under the same key every other platform uses, so it feeds `engagementBreakdown.videoViews` too; it is an engagement, NOT a conversion, and is excluded from `conversions`. Google returns {} (its per-action names aren't synced per ad). Empty object when no actions are reported. NOTE: keys differ by platform, so branch on the ad's platform when interpreting them.
836
880
  */
837
881
  actions?: {
838
882
  [key: string]: (number);
@@ -1229,6 +1273,18 @@ export type AdTreeAdSet = {
1229
1273
  budget?: {
1230
1274
  amount?: number;
1231
1275
  type?: 'daily' | 'lifetime';
1276
+ /**
1277
+ * LinkedIn only. The campaign's `dailyBudget`. LinkedIn allows a daily AND a lifetime budget on the same campaign, which `amount`/`type` cannot express (daily wins there); read `daily` and `lifetime` to see both.
1278
+ */
1279
+ daily?: number;
1280
+ /**
1281
+ * LinkedIn only. The campaign's `totalBudget`, readable even when a daily budget is also set.
1282
+ */
1283
+ lifetime?: number;
1284
+ /**
1285
+ * LinkedIn only. The campaign's `pacingStrategy`: how fast LinkedIn may spend the budget. Typically LINEAR or ACCELERATED; the list is open.
1286
+ */
1287
+ pacing?: string;
1232
1288
  } | null;
1233
1289
  /**
1234
1290
  * Ad-set-level budget (ABO). Null for CBO campaigns where the budget is set on the campaign.
@@ -1236,6 +1292,18 @@ export type AdTreeAdSet = {
1236
1292
  adSetBudget?: {
1237
1293
  amount?: number;
1238
1294
  type?: 'daily' | 'lifetime';
1295
+ /**
1296
+ * LinkedIn only. See `budget.daily`.
1297
+ */
1298
+ daily?: number;
1299
+ /**
1300
+ * LinkedIn only. See `budget.lifetime`.
1301
+ */
1302
+ lifetime?: number;
1303
+ /**
1304
+ * LinkedIn only. See `budget.pacing`.
1305
+ */
1306
+ pacing?: string;
1239
1307
  } | null;
1240
1308
  metrics?: AdMetrics;
1241
1309
  /**
@@ -2590,6 +2658,24 @@ export type CampaignAnalyticsResponse = {
2590
2658
  daily?: Array<(AdMetrics & {
2591
2659
  date?: string;
2592
2660
  })>;
2661
+ /**
2662
+ * Requested demographic breakdowns, keyed by dimension. Fetched live from the
2663
+ * platform per request and never stored, so these rows can carry fields the
2664
+ * stored `summary` and `daily` series do not.
2665
+ *
2666
+ * LinkedIn rows carry `value` (the pivot URN), `name` (resolved label where
2667
+ * LinkedIn provides one), the usual spend/impressions/clicks/ctr/cpc/cpm/engagement
2668
+ * figures, plus two reach fields:
2669
+ *
2670
+ * - `reach`: the segment's `approximateMemberReach`.
2671
+ * - `audiencePenetration`: LinkedIn's own ratio of members reached to the size of
2672
+ * the targeted audience, passed through verbatim.
2673
+ *
2674
+ * LinkedIn withholds both below its audience privacy threshold, in which case the
2675
+ * keys are ABSENT rather than 0. `audiencePenetration` is available here only: it
2676
+ * is not part of the stored metrics series.
2677
+ *
2678
+ */
2593
2679
  breakdowns?: {
2594
2680
  [key: string]: Array<{
2595
2681
  [key: string]: unknown;
@@ -34735,7 +34821,61 @@ export type ListAdSetsResponse = ({
34735
34821
  profileId?: string;
34736
34822
  currency?: (string) | null;
34737
34823
  budget?: {
34738
- [key: string]: unknown;
34824
+ amount?: number;
34825
+ type?: 'daily' | 'lifetime';
34826
+ /**
34827
+ * LinkedIn only. The campaign's `dailyBudget`. LinkedIn allows a daily AND a lifetime budget on the same campaign, which `amount`/`type` cannot express (daily wins there); read `daily` and `lifetime` to see both.
34828
+ */
34829
+ daily?: number;
34830
+ /**
34831
+ * LinkedIn only. The campaign's `totalBudget`, readable even when a daily budget is also set.
34832
+ */
34833
+ lifetime?: number;
34834
+ /**
34835
+ * LinkedIn only. The campaign's `pacingStrategy`: how fast LinkedIn may spend the budget. Typically LINEAR or ACCELERATED; the list is open.
34836
+ */
34837
+ pacing?: string;
34838
+ } | null;
34839
+ /**
34840
+ * The ad set's own flight dates, as synced from the platform. On LinkedIn this is the campaign's `runSchedule`. Null when the platform reports none.
34841
+ */
34842
+ schedule?: {
34843
+ startDate?: string;
34844
+ /**
34845
+ * Absent when the ad set runs until it is stopped.
34846
+ */
34847
+ endDate?: string;
34848
+ } | null;
34849
+ /**
34850
+ * The audience this ad set delivers to, as the platform reports it. LinkedIn only
34851
+ * today; null for every other platform and for LinkedIn ad sets not yet re-synced.
34852
+ *
34853
+ * `include` and `exclude` are the campaign's `targetingCriteria` verbatim, so they
34854
+ * can be read, edited and sent back without reconstructing them from our normalized
34855
+ * targeting spec. Exclusions were previously not readable at all.
34856
+ *
34857
+ */
34858
+ targeting?: {
34859
+ /**
34860
+ * LinkedIn `targetingCriteria.include`, verbatim (an `and` of `or` facet clauses).
34861
+ */
34862
+ include?: {
34863
+ [key: string]: unknown;
34864
+ };
34865
+ /**
34866
+ * LinkedIn `targetingCriteria.exclude`, verbatim. Absent when the campaign excludes nothing.
34867
+ */
34868
+ exclude?: {
34869
+ [key: string]: unknown;
34870
+ };
34871
+ /**
34872
+ * LinkedIn audience expansion: whether LinkedIn may also serve to members similar to the criteria.
34873
+ */
34874
+ audienceExpansionEnabled?: boolean;
34875
+ /**
34876
+ * Whether the campaign may deliver on the LinkedIn Audience Network, off LinkedIn itself.
34877
+ */
34878
+ offsiteDeliveryEnabled?: boolean;
34739
34879
  } | null;
34740
34880
  isExternal?: (boolean) | null;
34741
34881
  platformCreatedAt?: (string) | null;
@@ -40898,6 +41038,10 @@ export type EstimateAdReachResponse = ({
40898
41038
  * Optional estimated daily reach/results at the given budget, when the platform returns it.
40899
41039
  */
40900
41040
  daily?: (number) | null;
41041
+ /**
41042
+ * LinkedIn only. LinkedIn's `audienceCounts.active`, verbatim: the active subset of the same audience `lower`/`upper` carry as its `total`. Absent when LinkedIn does not report it; `0` is a real answer, not a missing one.
41043
+ */
41044
+ active?: (number) | null;
40901
41045
  /**
40902
41046
  * Currency of any monetary fields in the estimate, when applicable.
40903
41047
  */