@postrun/js 2.20.0 → 2.21.0

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/query.d.cts CHANGED
@@ -1294,6 +1294,10 @@ type GoogleAdsAudience = {
1294
1294
  status: 'UNSPECIFIED' | 'UNKNOWN' | 'ENABLED' | 'REMOVED';
1295
1295
  type: 'UNSPECIFIED' | 'UNKNOWN' | 'AUTO' | 'INTEREST' | 'PURCHASE_INTENT' | 'SEARCH';
1296
1296
  };
1297
+ /**
1298
+ * Filter by serving status (ENABLED / PAUSED / REMOVED). Omit to return everything except REMOVED.
1299
+ */
1300
+ type GoogleAdsReadStatusFilter = Array<'ENABLED' | 'PAUSED' | 'REMOVED'>;
1297
1301
  /**
1298
1302
  * A Google Ads campaign targeting criterion. LOCATION and LANGUAGE are fully modelled (with their geo_target_constant / language_constant, status, and negative flag); any other criterion type is returned as { type, criterion_id }.
1299
1303
  */
@@ -1446,13 +1450,21 @@ type GoogleAdsInsightsRow = {
1446
1450
  * The requested metrics keyed by name; only the metrics you asked for are present.
1447
1451
  */
1448
1452
  metrics: {
1449
- [key: string]: number | null;
1453
+ impressions?: number | null;
1454
+ clicks?: number | null;
1455
+ ctr?: number | null;
1456
+ average_cpc?: number | null;
1457
+ cost_micros?: number | null;
1458
+ conversions?: number | null;
1459
+ conversions_value?: number | null;
1460
+ cost_per_conversion?: number | null;
1450
1461
  };
1451
1462
  /**
1452
1463
  * The requested breakdowns keyed by segment name; present only when segments were requested.
1453
1464
  */
1454
1465
  segments?: {
1455
- [key: string]: string;
1466
+ date?: string;
1467
+ device?: string;
1456
1468
  };
1457
1469
  };
1458
1470
  /**
@@ -1501,11 +1513,22 @@ type GoogleAdTreeNode = {
1501
1513
  * Whether the tree read can fetch this node’s children today (true only for ad-group channel types in this version).
1502
1514
  */
1503
1515
  expandable: boolean;
1516
+ /**
1517
+ * The campaign’s average daily budget in micros (1/1,000,000 of the account currency). Present on campaign nodes only — null at ad_group / ad / keyword (and null when a campaign has no budget).
1518
+ */
1519
+ budget_micros: number | null;
1504
1520
  /**
1505
1521
  * The requested metrics keyed by name; only the metrics you asked for are present. Google’s authoritative per-level numbers (no client roll-up).
1506
1522
  */
1507
1523
  metrics: {
1508
- [key: string]: number | null;
1524
+ impressions?: number | null;
1525
+ clicks?: number | null;
1526
+ ctr?: number | null;
1527
+ average_cpc?: number | null;
1528
+ cost_micros?: number | null;
1529
+ conversions?: number | null;
1530
+ conversions_value?: number | null;
1531
+ cost_per_conversion?: number | null;
1509
1532
  };
1510
1533
  /**
1511
1534
  * Spend for this node in micros (1/1,000,000 of the account currency), as Google reports it.
@@ -11535,6 +11558,7 @@ type GoogleGetAdTreeData = {
11535
11558
  * Restrict to one campaign — returns that campaign’s subtree (ad groups + leaf). Omit for the campaign level.
11536
11559
  */
11537
11560
  campaign_id?: string;
11561
+ status?: GoogleAdsReadStatusFilter;
11538
11562
  /**
11539
11563
  * The metric columns to report. At least one.
11540
11564
  */
@@ -16755,6 +16779,7 @@ type GoogleListAdGroupsData = {
16755
16779
  * Only return ad groups under this campaign (its numeric id).
16756
16780
  */
16757
16781
  campaign_id?: string;
16782
+ status?: GoogleAdsReadStatusFilter;
16758
16783
  };
16759
16784
  url: '/google/{connection_id}/ad-groups';
16760
16785
  };
@@ -20780,6 +20805,7 @@ type GoogleListAdsData = {
20780
20805
  * Only return ads under this ad group (its numeric id).
20781
20806
  */
20782
20807
  ad_group_id?: string;
20808
+ status?: GoogleAdsReadStatusFilter;
20783
20809
  };
20784
20810
  url: '/google/{connection_id}/ads';
20785
20811
  };
@@ -23036,6 +23062,7 @@ type GoogleListKeywordsData = {
23036
23062
  * Only return keywords under this ad group (its numeric id).
23037
23063
  */
23038
23064
  ad_group_id?: string;
23065
+ status?: GoogleAdsReadStatusFilter;
23039
23066
  };
23040
23067
  url: '/google/{connection_id}/keywords';
23041
23068
  };
@@ -32700,7 +32727,7 @@ declare const googleGetAdTreeQueryKey: (options: Options<GoogleGetAdTreeData>) =
32700
32727
  *
32701
32728
  * **Authentication.** Secret `pr_` API key, or a browser-safe frontend token granting `ads:read` scoped to the profile that owns the connection.
32702
32729
  *
32703
- * The campaign → ad_group → ad/keyword tree as flat, native, typed nodes — group them by `parent_id` to assemble the tree. Without `campaign_id`, returns every campaign (all channel types) with a per-type `child_kind`/`expandable` hint. With `campaign_id`, returns that campaign’s whole supported subtree (ad groups + the type’s leaf — keywords for Search, ads for Display/Video/Demand Gen) in one batched fetch at a single window. Each node carries Google’s authoritative per-level metrics (no client roll-up), `cost_micros`, and `cost` (account currency).
32730
+ * The campaign → ad_group → ad/keyword tree as flat, native, typed nodes — group them by `parent_id` to assemble the tree. Without `campaign_id`, returns every campaign (all channel types) with a per-type `child_kind`/`expandable` hint. With `campaign_id`, returns that campaign’s whole supported subtree (ad groups + the type’s leaf — keywords for Search, ads for Display/Video/Demand Gen) in one batched fetch at a single window. By default REMOVED nodes are hidden at every level; pass `status` to filter to specific serving states (ENABLED / PAUSED / REMOVED). Each node carries `budget_micros` (campaign nodes only), Google’s authoritative per-level metrics (no client roll-up), `cost_micros`, and `cost` (account currency).
32704
32731
  */
32705
32732
  declare const googleGetAdTreeOptions: (options: Options<GoogleGetAdTreeData>) => _tanstack_react_query.OmitKeyof<_tanstack_react_query.UseQueryOptions<GoogleAdTree, GoogleGetAdTreeError, GoogleAdTree, [Pick<Options<GoogleGetAdTreeData>, "query" | "body" | "headers" | "path" | "baseUrl"> & {
32706
32733
  _id: string;
@@ -33056,7 +33083,7 @@ declare const googleListAdGroupsQueryKey: (options: Options<GoogleListAdGroupsDa
33056
33083
  *
33057
33084
  * **Authentication.** Secret `pr_` API key, or a browser-safe frontend token granting `ads:read` scoped to the profile that owns the connection.
33058
33085
  *
33059
- * Lists the ad groups (Google’s equivalent of an ad set) in the Google Ads account backing this connection — id, name, status, type, and parent campaign. Pass `campaign_id` to return only the ad groups under one campaign.
33086
+ * Lists the ad groups (Google’s equivalent of an ad set) in the Google Ads account backing this connection — id, name, status, type, and parent campaign. Pass `campaign_id` to return only the ad groups under one campaign. By default REMOVED ad groups are hidden; pass `status` to filter to specific serving states (ENABLED / PAUSED / REMOVED).
33060
33087
  */
33061
33088
  declare const googleListAdGroupsOptions: (options: Options<GoogleListAdGroupsData>) => _tanstack_react_query.OmitKeyof<_tanstack_react_query.UseQueryOptions<{
33062
33089
  object: "list";
@@ -33292,7 +33319,7 @@ declare const googleListAdsQueryKey: (options: Options<GoogleListAdsData>) => [P
33292
33319
  *
33293
33320
  * **Authentication.** Secret `pr_` API key, or a browser-safe frontend token granting `ads:read` scoped to the profile that owns the connection.
33294
33321
  *
33295
- * Returns the ads (the `ad_group_ad` resource) on the connection’s account — id, name, creative type, serving status, and the owning ad group. Pass `ad_group_id` to return only the ads under one ad group.
33322
+ * Returns the ads (the `ad_group_ad` resource) on the connection’s account — id, name, creative type, serving status, and the owning ad group. Pass `ad_group_id` to return only the ads under one ad group. By default REMOVED ads are hidden; pass `status` to filter to specific serving states (ENABLED / PAUSED / REMOVED).
33296
33323
  */
33297
33324
  declare const googleListAdsOptions: (options: Options<GoogleListAdsData>) => _tanstack_react_query.OmitKeyof<_tanstack_react_query.UseQueryOptions<{
33298
33325
  object: "list";
@@ -33408,7 +33435,7 @@ declare const googleListKeywordsQueryKey: (options: Options<GoogleListKeywordsDa
33408
33435
  *
33409
33436
  * **Authentication.** Secret `pr_` API key, or a browser-safe frontend token granting `ads:read` scoped to the profile that owns the connection.
33410
33437
  *
33411
- * Lists the keywords (`ad_group_criterion` of type KEYWORD) in the connection’s account — each with its criterion id, text, match type, status, negative flag, and owning ad group. Pass `ad_group_id` to return only the keywords under one ad group.
33438
+ * Lists the keywords (`ad_group_criterion` of type KEYWORD) in the connection’s account — each with its criterion id, text, match type, status, negative flag, and owning ad group. Pass `ad_group_id` to return only the keywords under one ad group. By default REMOVED keywords are hidden; pass `status` to filter to specific serving states (ENABLED / PAUSED / REMOVED).
33412
33439
  */
33413
33440
  declare const googleListKeywordsOptions: (options: Options<GoogleListKeywordsData>) => _tanstack_react_query.OmitKeyof<_tanstack_react_query.UseQueryOptions<{
33414
33441
  object: "list";
package/dist/query.d.ts CHANGED
@@ -1294,6 +1294,10 @@ type GoogleAdsAudience = {
1294
1294
  status: 'UNSPECIFIED' | 'UNKNOWN' | 'ENABLED' | 'REMOVED';
1295
1295
  type: 'UNSPECIFIED' | 'UNKNOWN' | 'AUTO' | 'INTEREST' | 'PURCHASE_INTENT' | 'SEARCH';
1296
1296
  };
1297
+ /**
1298
+ * Filter by serving status (ENABLED / PAUSED / REMOVED). Omit to return everything except REMOVED.
1299
+ */
1300
+ type GoogleAdsReadStatusFilter = Array<'ENABLED' | 'PAUSED' | 'REMOVED'>;
1297
1301
  /**
1298
1302
  * A Google Ads campaign targeting criterion. LOCATION and LANGUAGE are fully modelled (with their geo_target_constant / language_constant, status, and negative flag); any other criterion type is returned as { type, criterion_id }.
1299
1303
  */
@@ -1446,13 +1450,21 @@ type GoogleAdsInsightsRow = {
1446
1450
  * The requested metrics keyed by name; only the metrics you asked for are present.
1447
1451
  */
1448
1452
  metrics: {
1449
- [key: string]: number | null;
1453
+ impressions?: number | null;
1454
+ clicks?: number | null;
1455
+ ctr?: number | null;
1456
+ average_cpc?: number | null;
1457
+ cost_micros?: number | null;
1458
+ conversions?: number | null;
1459
+ conversions_value?: number | null;
1460
+ cost_per_conversion?: number | null;
1450
1461
  };
1451
1462
  /**
1452
1463
  * The requested breakdowns keyed by segment name; present only when segments were requested.
1453
1464
  */
1454
1465
  segments?: {
1455
- [key: string]: string;
1466
+ date?: string;
1467
+ device?: string;
1456
1468
  };
1457
1469
  };
1458
1470
  /**
@@ -1501,11 +1513,22 @@ type GoogleAdTreeNode = {
1501
1513
  * Whether the tree read can fetch this node’s children today (true only for ad-group channel types in this version).
1502
1514
  */
1503
1515
  expandable: boolean;
1516
+ /**
1517
+ * The campaign’s average daily budget in micros (1/1,000,000 of the account currency). Present on campaign nodes only — null at ad_group / ad / keyword (and null when a campaign has no budget).
1518
+ */
1519
+ budget_micros: number | null;
1504
1520
  /**
1505
1521
  * The requested metrics keyed by name; only the metrics you asked for are present. Google’s authoritative per-level numbers (no client roll-up).
1506
1522
  */
1507
1523
  metrics: {
1508
- [key: string]: number | null;
1524
+ impressions?: number | null;
1525
+ clicks?: number | null;
1526
+ ctr?: number | null;
1527
+ average_cpc?: number | null;
1528
+ cost_micros?: number | null;
1529
+ conversions?: number | null;
1530
+ conversions_value?: number | null;
1531
+ cost_per_conversion?: number | null;
1509
1532
  };
1510
1533
  /**
1511
1534
  * Spend for this node in micros (1/1,000,000 of the account currency), as Google reports it.
@@ -11535,6 +11558,7 @@ type GoogleGetAdTreeData = {
11535
11558
  * Restrict to one campaign — returns that campaign’s subtree (ad groups + leaf). Omit for the campaign level.
11536
11559
  */
11537
11560
  campaign_id?: string;
11561
+ status?: GoogleAdsReadStatusFilter;
11538
11562
  /**
11539
11563
  * The metric columns to report. At least one.
11540
11564
  */
@@ -16755,6 +16779,7 @@ type GoogleListAdGroupsData = {
16755
16779
  * Only return ad groups under this campaign (its numeric id).
16756
16780
  */
16757
16781
  campaign_id?: string;
16782
+ status?: GoogleAdsReadStatusFilter;
16758
16783
  };
16759
16784
  url: '/google/{connection_id}/ad-groups';
16760
16785
  };
@@ -20780,6 +20805,7 @@ type GoogleListAdsData = {
20780
20805
  * Only return ads under this ad group (its numeric id).
20781
20806
  */
20782
20807
  ad_group_id?: string;
20808
+ status?: GoogleAdsReadStatusFilter;
20783
20809
  };
20784
20810
  url: '/google/{connection_id}/ads';
20785
20811
  };
@@ -23036,6 +23062,7 @@ type GoogleListKeywordsData = {
23036
23062
  * Only return keywords under this ad group (its numeric id).
23037
23063
  */
23038
23064
  ad_group_id?: string;
23065
+ status?: GoogleAdsReadStatusFilter;
23039
23066
  };
23040
23067
  url: '/google/{connection_id}/keywords';
23041
23068
  };
@@ -32700,7 +32727,7 @@ declare const googleGetAdTreeQueryKey: (options: Options<GoogleGetAdTreeData>) =
32700
32727
  *
32701
32728
  * **Authentication.** Secret `pr_` API key, or a browser-safe frontend token granting `ads:read` scoped to the profile that owns the connection.
32702
32729
  *
32703
- * The campaign → ad_group → ad/keyword tree as flat, native, typed nodes — group them by `parent_id` to assemble the tree. Without `campaign_id`, returns every campaign (all channel types) with a per-type `child_kind`/`expandable` hint. With `campaign_id`, returns that campaign’s whole supported subtree (ad groups + the type’s leaf — keywords for Search, ads for Display/Video/Demand Gen) in one batched fetch at a single window. Each node carries Google’s authoritative per-level metrics (no client roll-up), `cost_micros`, and `cost` (account currency).
32730
+ * The campaign → ad_group → ad/keyword tree as flat, native, typed nodes — group them by `parent_id` to assemble the tree. Without `campaign_id`, returns every campaign (all channel types) with a per-type `child_kind`/`expandable` hint. With `campaign_id`, returns that campaign’s whole supported subtree (ad groups + the type’s leaf — keywords for Search, ads for Display/Video/Demand Gen) in one batched fetch at a single window. By default REMOVED nodes are hidden at every level; pass `status` to filter to specific serving states (ENABLED / PAUSED / REMOVED). Each node carries `budget_micros` (campaign nodes only), Google’s authoritative per-level metrics (no client roll-up), `cost_micros`, and `cost` (account currency).
32704
32731
  */
32705
32732
  declare const googleGetAdTreeOptions: (options: Options<GoogleGetAdTreeData>) => _tanstack_react_query.OmitKeyof<_tanstack_react_query.UseQueryOptions<GoogleAdTree, GoogleGetAdTreeError, GoogleAdTree, [Pick<Options<GoogleGetAdTreeData>, "query" | "body" | "headers" | "path" | "baseUrl"> & {
32706
32733
  _id: string;
@@ -33056,7 +33083,7 @@ declare const googleListAdGroupsQueryKey: (options: Options<GoogleListAdGroupsDa
33056
33083
  *
33057
33084
  * **Authentication.** Secret `pr_` API key, or a browser-safe frontend token granting `ads:read` scoped to the profile that owns the connection.
33058
33085
  *
33059
- * Lists the ad groups (Google’s equivalent of an ad set) in the Google Ads account backing this connection — id, name, status, type, and parent campaign. Pass `campaign_id` to return only the ad groups under one campaign.
33086
+ * Lists the ad groups (Google’s equivalent of an ad set) in the Google Ads account backing this connection — id, name, status, type, and parent campaign. Pass `campaign_id` to return only the ad groups under one campaign. By default REMOVED ad groups are hidden; pass `status` to filter to specific serving states (ENABLED / PAUSED / REMOVED).
33060
33087
  */
33061
33088
  declare const googleListAdGroupsOptions: (options: Options<GoogleListAdGroupsData>) => _tanstack_react_query.OmitKeyof<_tanstack_react_query.UseQueryOptions<{
33062
33089
  object: "list";
@@ -33292,7 +33319,7 @@ declare const googleListAdsQueryKey: (options: Options<GoogleListAdsData>) => [P
33292
33319
  *
33293
33320
  * **Authentication.** Secret `pr_` API key, or a browser-safe frontend token granting `ads:read` scoped to the profile that owns the connection.
33294
33321
  *
33295
- * Returns the ads (the `ad_group_ad` resource) on the connection’s account — id, name, creative type, serving status, and the owning ad group. Pass `ad_group_id` to return only the ads under one ad group.
33322
+ * Returns the ads (the `ad_group_ad` resource) on the connection’s account — id, name, creative type, serving status, and the owning ad group. Pass `ad_group_id` to return only the ads under one ad group. By default REMOVED ads are hidden; pass `status` to filter to specific serving states (ENABLED / PAUSED / REMOVED).
33296
33323
  */
33297
33324
  declare const googleListAdsOptions: (options: Options<GoogleListAdsData>) => _tanstack_react_query.OmitKeyof<_tanstack_react_query.UseQueryOptions<{
33298
33325
  object: "list";
@@ -33408,7 +33435,7 @@ declare const googleListKeywordsQueryKey: (options: Options<GoogleListKeywordsDa
33408
33435
  *
33409
33436
  * **Authentication.** Secret `pr_` API key, or a browser-safe frontend token granting `ads:read` scoped to the profile that owns the connection.
33410
33437
  *
33411
- * Lists the keywords (`ad_group_criterion` of type KEYWORD) in the connection’s account — each with its criterion id, text, match type, status, negative flag, and owning ad group. Pass `ad_group_id` to return only the keywords under one ad group.
33438
+ * Lists the keywords (`ad_group_criterion` of type KEYWORD) in the connection’s account — each with its criterion id, text, match type, status, negative flag, and owning ad group. Pass `ad_group_id` to return only the keywords under one ad group. By default REMOVED keywords are hidden; pass `status` to filter to specific serving states (ENABLED / PAUSED / REMOVED).
33412
33439
  */
33413
33440
  declare const googleListKeywordsOptions: (options: Options<GoogleListKeywordsData>) => _tanstack_react_query.OmitKeyof<_tanstack_react_query.UseQueryOptions<{
33414
33441
  object: "list";