@getlatedev/node 0.2.1248 → 0.2.1249
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 +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
- package/src/generated/sdk.gen.ts +41 -4
- package/src/generated/types.gen.ts +5 -5
package/dist/index.d.mts
CHANGED
|
@@ -2580,7 +2580,7 @@ type format = 'single_image' | 'carousel_images_multi_items' | 'carousel_images_
|
|
|
2580
2580
|
type AdActivationStatus = 'ACTIVE' | 'PAUSED';
|
|
2581
2581
|
type AdAnalyticsResponse = {
|
|
2582
2582
|
/**
|
|
2583
|
-
* Present and true while historical data is being backfilled.
|
|
2583
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
2584
2584
|
*/
|
|
2585
2585
|
backfillPending?: boolean;
|
|
2586
2586
|
ad?: {
|
|
@@ -3415,14 +3415,14 @@ type AdsListResponse = {
|
|
|
3415
3415
|
ads?: Array<Ad>;
|
|
3416
3416
|
pagination?: Pagination;
|
|
3417
3417
|
/**
|
|
3418
|
-
* Present and true while historical data is being backfilled.
|
|
3418
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
3419
3419
|
*/
|
|
3420
3420
|
backfillPending?: boolean;
|
|
3421
3421
|
};
|
|
3422
3422
|
type AdStatus = 'active' | 'paused' | 'pending_review' | 'rejected' | 'completed' | 'cancelled' | 'error';
|
|
3423
3423
|
type AdsTimelineResponse = {
|
|
3424
3424
|
/**
|
|
3425
|
-
* Present and true while historical data is being backfilled.
|
|
3425
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
3426
3426
|
*/
|
|
3427
3427
|
backfillPending?: boolean;
|
|
3428
3428
|
rows?: Array<{
|
|
@@ -3719,7 +3719,7 @@ type AdTreeResponse = {
|
|
|
3719
3719
|
campaigns?: Array<AdTreeCampaign>;
|
|
3720
3720
|
pagination?: Pagination;
|
|
3721
3721
|
/**
|
|
3722
|
-
* Present and true while historical data is being backfilled.
|
|
3722
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
3723
3723
|
*/
|
|
3724
3724
|
backfillPending?: boolean;
|
|
3725
3725
|
};
|
|
@@ -5109,7 +5109,7 @@ type transcriptionLanguage = 'auto' | 'en' | 'es';
|
|
|
5109
5109
|
type endReason = 'hangup' | 'no_answer' | 'rejected' | 'error';
|
|
5110
5110
|
type CampaignAnalyticsResponse = {
|
|
5111
5111
|
/**
|
|
5112
|
-
* Present and true while historical data is being backfilled.
|
|
5112
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
5113
5113
|
*/
|
|
5114
5114
|
backfillPending?: boolean;
|
|
5115
5115
|
campaign?: {
|
package/dist/index.d.ts
CHANGED
|
@@ -2580,7 +2580,7 @@ type format = 'single_image' | 'carousel_images_multi_items' | 'carousel_images_
|
|
|
2580
2580
|
type AdActivationStatus = 'ACTIVE' | 'PAUSED';
|
|
2581
2581
|
type AdAnalyticsResponse = {
|
|
2582
2582
|
/**
|
|
2583
|
-
* Present and true while historical data is being backfilled.
|
|
2583
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
2584
2584
|
*/
|
|
2585
2585
|
backfillPending?: boolean;
|
|
2586
2586
|
ad?: {
|
|
@@ -3415,14 +3415,14 @@ type AdsListResponse = {
|
|
|
3415
3415
|
ads?: Array<Ad>;
|
|
3416
3416
|
pagination?: Pagination;
|
|
3417
3417
|
/**
|
|
3418
|
-
* Present and true while historical data is being backfilled.
|
|
3418
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
3419
3419
|
*/
|
|
3420
3420
|
backfillPending?: boolean;
|
|
3421
3421
|
};
|
|
3422
3422
|
type AdStatus = 'active' | 'paused' | 'pending_review' | 'rejected' | 'completed' | 'cancelled' | 'error';
|
|
3423
3423
|
type AdsTimelineResponse = {
|
|
3424
3424
|
/**
|
|
3425
|
-
* Present and true while historical data is being backfilled.
|
|
3425
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
3426
3426
|
*/
|
|
3427
3427
|
backfillPending?: boolean;
|
|
3428
3428
|
rows?: Array<{
|
|
@@ -3719,7 +3719,7 @@ type AdTreeResponse = {
|
|
|
3719
3719
|
campaigns?: Array<AdTreeCampaign>;
|
|
3720
3720
|
pagination?: Pagination;
|
|
3721
3721
|
/**
|
|
3722
|
-
* Present and true while historical data is being backfilled.
|
|
3722
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
3723
3723
|
*/
|
|
3724
3724
|
backfillPending?: boolean;
|
|
3725
3725
|
};
|
|
@@ -5109,7 +5109,7 @@ type transcriptionLanguage = 'auto' | 'en' | 'es';
|
|
|
5109
5109
|
type endReason = 'hangup' | 'no_answer' | 'rejected' | 'error';
|
|
5110
5110
|
type CampaignAnalyticsResponse = {
|
|
5111
5111
|
/**
|
|
5112
|
-
* Present and true while historical data is being backfilled.
|
|
5112
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
5113
5113
|
*/
|
|
5114
5114
|
backfillPending?: boolean;
|
|
5115
5115
|
campaign?: {
|
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.
|
|
39
|
+
version: "0.2.1249",
|
|
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.
|
|
8
|
+
version: "0.2.1249",
|
|
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
package/src/generated/sdk.gen.ts
CHANGED
|
@@ -9738,6 +9738,13 @@ export const listCommentAutomationLogs = <ThrowOnError extends boolean = false>(
|
|
|
9738
9738
|
* Use source=all to include externally-synced ads from platform ad managers.
|
|
9739
9739
|
* If no date range is provided, defaults to the last 90 days. Date range is capped at 730 days max.
|
|
9740
9740
|
*
|
|
9741
|
+
* History: when an ad account connects, Zernio imports its last 90 days of metrics, so the
|
|
9742
|
+
* metrics hold no data for days before that. When `accountId` or `adAccountId` resolves to a
|
|
9743
|
+
* Meta ad account, a range reaching further back answers `202` with `backfillPending: true` and the
|
|
9744
|
+
* covered part while the older days (up to 730 days back) are imported in the background;
|
|
9745
|
+
* repeat the request until it returns 200.
|
|
9746
|
+
* A request scoped to no Meta account never returns `202`.
|
|
9747
|
+
*
|
|
9741
9748
|
* To find the Zernio ad behind a comment you see in Meta Business Manager, filter by
|
|
9742
9749
|
* platformAdId (the Meta ad ID), effectiveObjectStoryId (Facebook), or
|
|
9743
9750
|
* effectiveInstagramMediaId (Instagram). Those are the post/media the ad's engagement
|
|
@@ -10790,6 +10797,13 @@ export const updateAdSetStatus = <ThrowOnError extends boolean = false>(options:
|
|
|
10790
10797
|
* ID are grouped into synthetic "Ungrouped" buckets.
|
|
10791
10798
|
* If no date range is provided, defaults to the last 90 days. Date range is capped at 730 days max.
|
|
10792
10799
|
*
|
|
10800
|
+
* History: when an ad account connects, Zernio imports its last 90 days of metrics, so the
|
|
10801
|
+
* metrics hold no data for days before that. When `accountId` or `adAccountId` resolves to a
|
|
10802
|
+
* Meta ad account, a range reaching further back answers `202` with `backfillPending: true` and the
|
|
10803
|
+
* covered part while the older days (up to 730 days back) are imported in the background;
|
|
10804
|
+
* repeat the request until it returns 200.
|
|
10805
|
+
* A request scoped to no Meta account never returns `202`.
|
|
10806
|
+
*
|
|
10793
10807
|
* Pass `timeIncrement=1` to also get a daily breakdown: each node gains a `daily[]` array of
|
|
10794
10808
|
* per-day metrics (same fields as the aggregated `metrics`) in the same call. Use `dailyLevel`
|
|
10795
10809
|
* (`campaign` default, or `adset` / `ad`) to choose which levels carry the series. This replaces
|
|
@@ -10822,10 +10836,14 @@ export const getAdTree = <ThrowOnError extends boolean = false>(options?: Option
|
|
|
10822
10836
|
* ID also includes ads under the linked `facebook` / `instagram` posting account
|
|
10823
10837
|
* (and vice-versa), the same convention as `/v1/ads/tree` and `/v1/ads`.
|
|
10824
10838
|
*
|
|
10825
|
-
* Date range defaults to the last 90 days. Capped at 730 days.
|
|
10826
|
-
*
|
|
10827
|
-
*
|
|
10828
|
-
*
|
|
10839
|
+
* Date range defaults to the last 90 days. Capped at 730 days.
|
|
10840
|
+
*
|
|
10841
|
+
* History: when an ad account connects, Zernio imports its last 90 days of metrics, so `rows`
|
|
10842
|
+
* hold no data for days before that. When `accountId` or `adAccountId` resolves to a Meta ad
|
|
10843
|
+
* account, a range reaching further back answers `202` with `backfillPending: true` and the
|
|
10844
|
+
* covered part while the older days (up to 730 days back) are imported in the background;
|
|
10845
|
+
* repeat the request until it returns 200.
|
|
10846
|
+
* Other platforms never return `202`.
|
|
10829
10847
|
*
|
|
10830
10848
|
* With adAccountId set to a Google customer id this is the customer-level performance report (clicks, cost, impressions, conversions, all conversions per day).
|
|
10831
10849
|
*
|
|
@@ -11176,6 +11194,16 @@ export const removeAdGroupAssets = <ThrowOnError extends boolean = false>(option
|
|
|
11176
11194
|
* age/gender/placement/etc. without summing thousands of per-ad reads. `campaignId` is the platform campaign id; pass
|
|
11177
11195
|
* `platform` when a campaign id could be ambiguous across platforms. If no date range is provided,
|
|
11178
11196
|
* defaults to the last 90 days. Date range is capped at 730 days max.
|
|
11197
|
+
*
|
|
11198
|
+
* History: when an ad account connects, Zernio imports its last 90 days of metrics. `summary`
|
|
11199
|
+
* and `daily` come from those synced metrics, so they hold no data for days before that.
|
|
11200
|
+
* Breakdowns and Google's impression share are read live from the platform over the requested
|
|
11201
|
+
* range, so they are not limited by the import.
|
|
11202
|
+
* When the campaign belongs to a Meta ad account, a range reaching further back answers `202` with `backfillPending: true` and the
|
|
11203
|
+
* covered part while the older days (up to 730 days back) are imported in the background;
|
|
11204
|
+
* repeat the request until it returns 200.
|
|
11205
|
+
* Other platforms never return `202`.
|
|
11206
|
+
*
|
|
11179
11207
|
* Google adds searchImpressionShare, searchBudgetLostImpressionShare,
|
|
11180
11208
|
* searchRankLostImpressionShare, searchTopImpressionShare and searchAbsoluteTopImpressionShare
|
|
11181
11209
|
* under analytics.summary for the requested inclusive range. These ratios are queried
|
|
@@ -11420,6 +11448,15 @@ export const getAdInsightsReport = <ThrowOnError extends boolean = false>(option
|
|
|
11420
11448
|
* over the requested date range, and optional demographic breakdowns (Meta, TikTok and LinkedIn only).
|
|
11421
11449
|
* If no date range is provided, defaults to the last 90 days. Date range is capped at 730 days max.
|
|
11422
11450
|
*
|
|
11451
|
+
* History: when an ad account connects, Zernio imports its last 90 days of metrics. `summary`
|
|
11452
|
+
* and `daily` come from those synced metrics, so they hold no data for days before that.
|
|
11453
|
+
* Breakdowns are read live from the platform over the requested range, so they are not limited
|
|
11454
|
+
* by the import.
|
|
11455
|
+
* When the ad belongs to a Meta ad account, a range reaching further back answers `202` with `backfillPending: true` and the
|
|
11456
|
+
* covered part while the older days (up to 730 days back) are imported in the background;
|
|
11457
|
+
* repeat the request until it returns 200.
|
|
11458
|
+
* Other platforms never return `202`.
|
|
11459
|
+
*
|
|
11423
11460
|
*/
|
|
11424
11461
|
export const getAdAnalytics = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<GetAdAnalyticsData, ThrowOnError>) => {
|
|
11425
11462
|
return (options?.client ?? client).get<GetAdAnalyticsResponse, GetAdAnalyticsError, ThrowOnError>({
|
|
@@ -564,7 +564,7 @@ export type AdActivationStatus = 'ACTIVE' | 'PAUSED';
|
|
|
564
564
|
|
|
565
565
|
export type AdAnalyticsResponse = {
|
|
566
566
|
/**
|
|
567
|
-
* Present and true while historical data is being backfilled.
|
|
567
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
568
568
|
*/
|
|
569
569
|
backfillPending?: boolean;
|
|
570
570
|
ad?: {
|
|
@@ -1424,7 +1424,7 @@ export type AdsListResponse = {
|
|
|
1424
1424
|
ads?: Array<Ad>;
|
|
1425
1425
|
pagination?: Pagination;
|
|
1426
1426
|
/**
|
|
1427
|
-
* Present and true while historical data is being backfilled.
|
|
1427
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
1428
1428
|
*/
|
|
1429
1429
|
backfillPending?: boolean;
|
|
1430
1430
|
};
|
|
@@ -1433,7 +1433,7 @@ export type AdStatus = 'active' | 'paused' | 'pending_review' | 'rejected' | 'co
|
|
|
1433
1433
|
|
|
1434
1434
|
export type AdsTimelineResponse = {
|
|
1435
1435
|
/**
|
|
1436
|
-
* Present and true while historical data is being backfilled.
|
|
1436
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
1437
1437
|
*/
|
|
1438
1438
|
backfillPending?: boolean;
|
|
1439
1439
|
rows?: Array<{
|
|
@@ -1734,7 +1734,7 @@ export type AdTreeResponse = {
|
|
|
1734
1734
|
campaigns?: Array<AdTreeCampaign>;
|
|
1735
1735
|
pagination?: Pagination;
|
|
1736
1736
|
/**
|
|
1737
|
-
* Present and true while historical data is being backfilled.
|
|
1737
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
1738
1738
|
*/
|
|
1739
1739
|
backfillPending?: boolean;
|
|
1740
1740
|
};
|
|
@@ -3206,7 +3206,7 @@ export type endReason = 'hangup' | 'no_answer' | 'rejected' | 'error';
|
|
|
3206
3206
|
|
|
3207
3207
|
export type CampaignAnalyticsResponse = {
|
|
3208
3208
|
/**
|
|
3209
|
-
* Present and true while historical data is being backfilled.
|
|
3209
|
+
* Meta only. Present and true while historical data is being backfilled.
|
|
3210
3210
|
*/
|
|
3211
3211
|
backfillPending?: boolean;
|
|
3212
3212
|
campaign?: {
|