@getlatedev/node 0.2.389 → 0.2.391

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.
@@ -3910,6 +3910,43 @@ export type ReviewWebhookReview = {
3910
3910
  */
3911
3911
  export type platform4 = 'googlebusiness';
3912
3912
 
3913
+ /**
3914
+ * A Meta Reach & Frequency prediction. Money values in whole units of the ad account currency.
3915
+ */
3916
+ export type RfPrediction = {
3917
+ predictionId?: string;
3918
+ /**
3919
+ * ready | pending | failed:<meta code>
3920
+ */
3921
+ status?: string;
3922
+ /**
3923
+ * Quoted (or provided) lifetime budget for the window.
3924
+ */
3925
+ budget?: (number) | null;
3926
+ /**
3927
+ * Predicted (or requested) unique reach.
3928
+ */
3929
+ reach?: (number) | null;
3930
+ impressions?: (number) | null;
3931
+ /**
3932
+ * Meta's allowed lower bound for this spec.
3933
+ */
3934
+ minBudget?: (number) | null;
3935
+ maxBudget?: (number) | null;
3936
+ minReach?: (number) | null;
3937
+ maxReach?: (number) | null;
3938
+ frequencyCap?: (number) | null;
3939
+ /**
3940
+ * Unix seconds; the reserved window the R&F ad set will run on.
3941
+ */
3942
+ startTime?: (number) | null;
3943
+ stopTime?: (number) | null;
3944
+ /**
3945
+ * When the reservation's locked price expires (set after reserving).
3946
+ */
3947
+ expiresAt?: (string) | null;
3948
+ };
3949
+
3913
3950
  /**
3914
3951
  * An ad account a tracking tag is shared with (Meta `shared_accounts` edge).
3915
3952
  */
@@ -23708,6 +23745,38 @@ export type DuplicateAdCampaignError = (unknown | {
23708
23745
  error?: string;
23709
23746
  });
23710
23747
 
23748
+ export type GetAdSetDetailsData = {
23749
+ path: {
23750
+ /**
23751
+ * Meta ad set id (platformAdSetId).
23752
+ */
23753
+ adSetId: string;
23754
+ };
23755
+ query: {
23756
+ /**
23757
+ * Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
23758
+ */
23759
+ accountId: string;
23760
+ /**
23761
+ * Comma-separated Graph field override (supports nested {} projections).
23762
+ */
23763
+ fields?: string;
23764
+ };
23765
+ };
23766
+
23767
+ export type GetAdSetDetailsResponse = ({
23768
+ /**
23769
+ * Raw Meta ad set; keys are the requested Graph fields.
23770
+ */
23771
+ adSet?: {
23772
+ [key: string]: unknown;
23773
+ };
23774
+ });
23775
+
23776
+ export type GetAdSetDetailsError = (unknown | {
23777
+ error?: string;
23778
+ });
23779
+
23711
23780
  export type UpdateAdSetData = {
23712
23781
  body: {
23713
23782
  platform: 'facebook' | 'instagram' | 'tiktok' | 'linkedin' | 'pinterest' | 'google' | 'twitter';
@@ -24708,6 +24777,252 @@ export type ListAdsBusinessCentersError = ({
24708
24777
  error?: string;
24709
24778
  } | unknown);
24710
24779
 
24780
+ export type GetAdsActivityLogData = {
24781
+ query: {
24782
+ /**
24783
+ * Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
24784
+ */
24785
+ accountId: string;
24786
+ /**
24787
+ * Meta ad account id (act_<n>).
24788
+ */
24789
+ adAccountId: string;
24790
+ /**
24791
+ * Cursor from paging.after of the previous page.
24792
+ */
24793
+ after?: string;
24794
+ /**
24795
+ * Rows per page
24796
+ */
24797
+ limit?: number;
24798
+ /**
24799
+ * Client-side filter to one Meta object id (campaign, ad set or ad).
24800
+ */
24801
+ objectId?: string;
24802
+ /**
24803
+ * Start of range (YYYY-MM-DD).
24804
+ */
24805
+ since?: string;
24806
+ /**
24807
+ * End of range (YYYY-MM-DD).
24808
+ */
24809
+ until?: string;
24810
+ };
24811
+ };
24812
+
24813
+ export type GetAdsActivityLogResponse = ({
24814
+ adAccountId?: string;
24815
+ data?: Array<{
24816
+ [key: string]: unknown;
24817
+ }>;
24818
+ paging?: {
24819
+ /**
24820
+ * Cursor for the next page; null when exhausted.
24821
+ */
24822
+ after?: (string) | null;
24823
+ };
24824
+ });
24825
+
24826
+ export type GetAdsActivityLogError = (unknown | {
24827
+ error?: string;
24828
+ });
24829
+
24830
+ export type CreateRfPredictionData = {
24831
+ body: {
24832
+ /**
24833
+ * Zernio SocialAccount id (posting or ads variant).
24834
+ */
24835
+ accountId: string;
24836
+ /**
24837
+ * Meta ad account id (act_<n>).
24838
+ */
24839
+ adAccountId: string;
24840
+ /**
24841
+ * Whole currency units. Exactly one of budgetAmount / reach.
24842
+ */
24843
+ budgetAmount?: number;
24844
+ /**
24845
+ * Target unique reach. Exactly one of budgetAmount / reach.
24846
+ */
24847
+ reach?: number;
24848
+ /**
24849
+ * Campaign window start (must be in the future).
24850
+ */
24851
+ startDate: string;
24852
+ endDate: string;
24853
+ /**
24854
+ * Max impressions per person over the window.
24855
+ */
24856
+ frequencyCap?: number;
24857
+ /**
24858
+ * Canonical camelCase TargetingSpec (same shape as /v1/ads/create's `targeting`). Defaults to countries: [US].
24859
+ */
24860
+ targeting?: {
24861
+ [key: string]: unknown;
24862
+ };
24863
+ /**
24864
+ * Meta placements object (same shape as /v1/ads/create's `placements`).
24865
+ */
24866
+ placements?: {
24867
+ [key: string]: unknown;
24868
+ };
24869
+ };
24870
+ };
24871
+
24872
+ export type CreateRfPredictionResponse = ({
24873
+ adAccountId?: string;
24874
+ currency?: string;
24875
+ prediction?: RfPrediction;
24876
+ });
24877
+
24878
+ export type CreateRfPredictionError = (unknown | {
24879
+ error?: string;
24880
+ });
24881
+
24882
+ export type GetRfPredictionData = {
24883
+ path: {
24884
+ predictionId: string;
24885
+ };
24886
+ query: {
24887
+ accountId: string;
24888
+ adAccountId: string;
24889
+ };
24890
+ };
24891
+
24892
+ export type GetRfPredictionResponse = ({
24893
+ adAccountId?: string;
24894
+ currency?: string;
24895
+ prediction?: RfPrediction;
24896
+ });
24897
+
24898
+ export type GetRfPredictionError = (unknown | {
24899
+ error?: string;
24900
+ });
24901
+
24902
+ export type CancelRfReservationData = {
24903
+ path: {
24904
+ predictionId: string;
24905
+ };
24906
+ query: {
24907
+ accountId: string;
24908
+ adAccountId: string;
24909
+ };
24910
+ };
24911
+
24912
+ export type CancelRfReservationResponse = (unknown);
24913
+
24914
+ export type CancelRfReservationError = (unknown | {
24915
+ error?: string;
24916
+ });
24917
+
24918
+ export type ReserveRfPredictionData = {
24919
+ body: {
24920
+ accountId: string;
24921
+ adAccountId: string;
24922
+ };
24923
+ path: {
24924
+ predictionId: string;
24925
+ };
24926
+ };
24927
+
24928
+ export type ReserveRfPredictionResponse = ({
24929
+ adAccountId?: string;
24930
+ prediction?: RfPrediction;
24931
+ });
24932
+
24933
+ export type ReserveRfPredictionError = (unknown | {
24934
+ error?: string;
24935
+ });
24936
+
24937
+ export type ListAdStudiesData = {
24938
+ query: {
24939
+ /**
24940
+ * Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
24941
+ */
24942
+ accountId: string;
24943
+ /**
24944
+ * Meta ad account id (act_<n>).
24945
+ */
24946
+ adAccountId: string;
24947
+ /**
24948
+ * Cursor from paging.after of the previous page.
24949
+ */
24950
+ after?: string;
24951
+ /**
24952
+ * Comma-separated Graph field override (supports nested {} projections).
24953
+ */
24954
+ fields?: string;
24955
+ /**
24956
+ * Rows per page
24957
+ */
24958
+ limit?: number;
24959
+ };
24960
+ };
24961
+
24962
+ export type ListAdStudiesResponse = ({
24963
+ adAccountId?: string;
24964
+ data?: Array<{
24965
+ [key: string]: unknown;
24966
+ }>;
24967
+ paging?: {
24968
+ /**
24969
+ * Cursor for the next page; null when exhausted.
24970
+ */
24971
+ after?: (string) | null;
24972
+ };
24973
+ });
24974
+
24975
+ export type ListAdStudiesError = (unknown | {
24976
+ error?: string;
24977
+ });
24978
+
24979
+ export type GetAdAccountFinanceData = {
24980
+ query: {
24981
+ /**
24982
+ * Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
24983
+ */
24984
+ accountId: string;
24985
+ /**
24986
+ * Meta ad account id (act_<n>).
24987
+ */
24988
+ adAccountId: string;
24989
+ };
24990
+ };
24991
+
24992
+ export type GetAdAccountFinanceResponse = ({
24993
+ adAccountId?: string;
24994
+ /**
24995
+ * ISO 4217 code all money values are expressed in.
24996
+ */
24997
+ currency?: string;
24998
+ /**
24999
+ * Outstanding/prepaid balance in whole currency units.
25000
+ */
25001
+ balance?: number;
25002
+ /**
25003
+ * Lifetime amount spent in whole currency units.
25004
+ */
25005
+ amountSpent?: number;
25006
+ /**
25007
+ * Account spend cap; null when none is set.
25008
+ */
25009
+ spendCap?: (number) | null;
25010
+ fundingSource?: {
25011
+ /**
25012
+ * Human-readable payment method, e.g. 'Mastercard *4985'.
25013
+ */
25014
+ displayString?: string;
25015
+ /**
25016
+ * Meta funding source type code.
25017
+ */
25018
+ type?: number;
25019
+ } | null;
25020
+ });
25021
+
25022
+ export type GetAdAccountFinanceError = (unknown | {
25023
+ error?: string;
25024
+ });
25025
+
24711
25026
  export type ListAdAccountsData = {
24712
25027
  query: {
24713
25028
  /**
@@ -25010,7 +25325,7 @@ export type BoostPostData = {
25010
25325
  /**
25011
25326
  * Meta only. Required for housing, employment, credit, or political ads.
25012
25327
  */
25013
- specialAdCategories?: Array<('HOUSING' | 'EMPLOYMENT' | 'CREDIT' | 'ISSUES_ELECTIONS_POLITICS')>;
25328
+ specialAdCategories?: Array<('HOUSING' | 'EMPLOYMENT' | 'CREDIT' | 'FINANCIAL_PRODUCTS_SERVICES' | 'ISSUES_ELECTIONS_POLITICS' | 'ONLINE_GAMBLING_AND_GAMING')>;
25014
25329
  /**
25015
25330
  * TikTok-only. Custom destination URL for the Spark Ad. Without this, TikTok
25016
25331
  * Spark Ads have no clickable destination — required for traffic / conversion
@@ -25128,6 +25443,14 @@ export type CreateStandaloneAdData = {
25128
25443
  * Meta only. Explicit ad-set `billing_event`. Defaults to `IMPRESSIONS`. Forwarded verbatim to Meta, which validates compatibility with the optimization goal.
25129
25444
  */
25130
25445
  billingEvent?: string;
25446
+ /**
25447
+ * Meta only. RESERVED = Reach & Frequency: requires `rfPredictionId` (a RESERVED prediction from /v1/ads/rf-predictions + /reserve). Budget, schedule and pricing come from the reservation, so budgetAmount/budgetType are not required and bid fields are ignored. Only the plain single-ad shape (no creatives[], adSetId, existingCampaignId or dynamicCreative).
25448
+ */
25449
+ buyingType?: 'AUCTION' | 'RESERVED';
25450
+ /**
25451
+ * Meta only. The RESERVED prediction id the R&F ad set runs on (reserving mints a new id — pass that one). Requires buyingType RESERVED.
25452
+ */
25453
+ rfPredictionId?: string;
25131
25454
  /**
25132
25455
  * Required on legacy + multi-creative shapes. Inherited on attach.
25133
25456
  */
@@ -25172,7 +25495,7 @@ export type CreateStandaloneAdData = {
25172
25495
  /**
25173
25496
  * Required on legacy + attach shapes for Meta. Honoured on TikTok (passes through to the Spark Ad creative's `call_to_action`) and on LinkedIn (the CTA button on the ad; defaults to LEARN_MORE when `linkUrl` is set). LinkedIn accepts: LEARN_MORE, SIGN_UP, DOWNLOAD, SUBSCRIBE, REGISTER, JOIN, ATTEND, REQUEST_DEMO, VIEW_QUOTE, APPLY, SEE_MORE, SHOP_NOW, BUY_NOW. Ignored by Google, Pinterest, and X/Twitter.
25174
25497
  */
25175
- callToAction?: 'LEARN_MORE' | 'SHOP_NOW' | 'SIGN_UP' | 'BOOK_TRAVEL' | 'CONTACT_US' | 'DOWNLOAD' | 'GET_OFFER' | 'GET_QUOTE' | 'SUBSCRIBE' | 'WATCH_MORE' | 'REGISTER' | 'JOIN' | 'ATTEND' | 'REQUEST_DEMO' | 'VIEW_QUOTE' | 'APPLY' | 'SEE_MORE' | 'BUY_NOW';
25498
+ callToAction?: 'LEARN_MORE' | 'SHOP_NOW' | 'SIGN_UP' | 'BOOK_TRAVEL' | 'CONTACT_US' | 'DOWNLOAD' | 'GET_OFFER' | 'GET_QUOTE' | 'SUBSCRIBE' | 'WATCH_MORE' | 'ADD_TO_CART' | 'APPLY_NOW' | 'BOOK_NOW' | 'BUY_TICKETS' | 'DONATE' | 'DONATE_NOW' | 'GET_DIRECTIONS' | 'GET_SHOWTIMES' | 'LISTEN_NOW' | 'ORDER_NOW' | 'PLAY_GAME' | 'REQUEST_TIME' | 'SEE_MENU' | 'START_ORDER' | 'INSTALL_MOBILE_APP' | 'USE_APP' | 'REGISTER' | 'JOIN' | 'ATTEND' | 'REQUEST_DEMO' | 'VIEW_QUOTE' | 'APPLY' | 'SEE_MORE' | 'BUY_NOW';
25176
25499
  /**
25177
25500
  * Required on legacy + attach shapes (skip for multi-creative). On LinkedIn it's the ad's destination URL; required for `traffic` ads, optional for `engagement` / `awareness`. NOT required when `goal` is `lead_generation` (the ad opens a Lead Gen form instead of a destination). On LinkedIn, `imageUrl` + `linkUrl` publishes an ARTICLE-content creative; this is LinkedIn's article ad format, with the image as thumbnail and `longHeadline` as description.
25178
25501
  */
@@ -25241,7 +25564,7 @@ export type CreateStandaloneAdData = {
25241
25564
  thumbnailUrl?: string;
25242
25565
  };
25243
25566
  linkUrl: string;
25244
- callToAction: 'LEARN_MORE' | 'SHOP_NOW' | 'SIGN_UP' | 'BOOK_TRAVEL' | 'CONTACT_US' | 'DOWNLOAD' | 'GET_OFFER' | 'GET_QUOTE' | 'SUBSCRIBE' | 'WATCH_MORE';
25567
+ callToAction: 'LEARN_MORE' | 'SHOP_NOW' | 'SIGN_UP' | 'BOOK_TRAVEL' | 'CONTACT_US' | 'DOWNLOAD' | 'GET_OFFER' | 'GET_QUOTE' | 'SUBSCRIBE' | 'WATCH_MORE' | 'ADD_TO_CART' | 'APPLY_NOW' | 'BOOK_NOW' | 'BUY_TICKETS' | 'DONATE' | 'DONATE_NOW' | 'GET_DIRECTIONS' | 'GET_SHOWTIMES' | 'LISTEN_NOW' | 'ORDER_NOW' | 'PLAY_GAME' | 'REQUEST_TIME' | 'SEE_MENU' | 'START_ORDER' | 'INSTALL_MOBILE_APP' | 'USE_APP';
25245
25568
  }>;
25246
25569
  /**
25247
25570
  * Meta-only. When present, switches to the attach shape: adds
@@ -25463,7 +25786,7 @@ export type CreateStandaloneAdData = {
25463
25786
  * category disables income/zip targeting on Meta.
25464
25787
  *
25465
25788
  */
25466
- specialAdCategories?: Array<('HOUSING' | 'EMPLOYMENT' | 'CREDIT' | 'ISSUES_ELECTIONS_POLITICS')>;
25789
+ specialAdCategories?: Array<('HOUSING' | 'EMPLOYMENT' | 'CREDIT' | 'FINANCIAL_PRODUCTS_SERVICES' | 'ISSUES_ELECTIONS_POLITICS' | 'ONLINE_GAMBLING_AND_GAMING')>;
25467
25790
  /**
25468
25791
  * Required for lifetime budgets
25469
25792
  */
@@ -25517,7 +25840,7 @@ export type CreateStandaloneAdData = {
25517
25840
  /**
25518
25841
  * CTA-button variations. Required.
25519
25842
  */
25520
- callToActionTypes?: Array<('LEARN_MORE' | 'SHOP_NOW' | 'SIGN_UP' | 'BOOK_TRAVEL' | 'CONTACT_US' | 'DOWNLOAD' | 'GET_OFFER' | 'GET_QUOTE' | 'SUBSCRIBE' | 'WATCH_MORE' | 'REGISTER' | 'JOIN' | 'ATTEND' | 'REQUEST_DEMO' | 'VIEW_QUOTE' | 'APPLY' | 'SEE_MORE' | 'BUY_NOW')>;
25843
+ callToActionTypes?: Array<('LEARN_MORE' | 'SHOP_NOW' | 'SIGN_UP' | 'BOOK_TRAVEL' | 'CONTACT_US' | 'DOWNLOAD' | 'GET_OFFER' | 'GET_QUOTE' | 'SUBSCRIBE' | 'WATCH_MORE' | 'ADD_TO_CART' | 'APPLY_NOW' | 'BOOK_NOW' | 'BUY_TICKETS' | 'DONATE' | 'DONATE_NOW' | 'GET_DIRECTIONS' | 'GET_SHOWTIMES' | 'LISTEN_NOW' | 'ORDER_NOW' | 'PLAY_GAME' | 'REQUEST_TIME' | 'SEE_MENU' | 'START_ORDER' | 'INSTALL_MOBILE_APP' | 'USE_APP' | 'REGISTER' | 'JOIN' | 'ATTEND' | 'REQUEST_DEMO' | 'VIEW_QUOTE' | 'APPLY' | 'SEE_MORE' | 'BUY_NOW')>;
25521
25844
  /**
25522
25845
  * Asset-feed ad format. Defaults to SINGLE_IMAGE.
25523
25846
  */
@@ -26094,6 +26417,45 @@ export type CreateTestLeadError = ({
26094
26417
  error?: string;
26095
26418
  });
26096
26419
 
26420
+ export type UploadAdImageData = {
26421
+ body: {
26422
+ /**
26423
+ * Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
26424
+ */
26425
+ accountId: string;
26426
+ /**
26427
+ * Meta ad account id (act_<n>).
26428
+ */
26429
+ adAccountId: string;
26430
+ /**
26431
+ * Raw base64 image bytes, or a full data URL (the data:image/...;base64, prefix is stripped).
26432
+ */
26433
+ imageBase64: string;
26434
+ /**
26435
+ * Optional filename shown in Meta's image library. Defaults to ad_image.jpg.
26436
+ */
26437
+ filename?: string;
26438
+ };
26439
+ };
26440
+
26441
+ export type UploadAdImageResponse = ({
26442
+ adAccountId?: string;
26443
+ image?: {
26444
+ /**
26445
+ * Meta image hash, reusable wherever image_hash is accepted.
26446
+ */
26447
+ hash?: string;
26448
+ /**
26449
+ * Meta-hosted image URL; usable as imageUrl on the create endpoints.
26450
+ */
26451
+ url?: string;
26452
+ };
26453
+ });
26454
+
26455
+ export type UploadAdImageError = (unknown | {
26456
+ error?: string;
26457
+ });
26458
+
26097
26459
  export type SearchAdInterestsData = {
26098
26460
  query: {
26099
26461
  /**
@@ -26741,8 +27103,12 @@ export type SendConversionsData = {
26741
27103
  testCode?: string;
26742
27104
  /**
26743
27105
  * Batch-level user consent. Required by Google for EEA/UK
26744
- * events under the Feb 2026 restrictions. Ignored by Meta
26745
- * and LinkedIn.
27106
+ * events under the Feb 2026 restrictions. On Meta, any
27107
+ * DENIED flag enables Limited Data Use on every event in
27108
+ * the batch (data_processing_options ["LDU"] with
27109
+ * geolocation, country 0 / state 0); GRANTED or absent
27110
+ * consent sends events with Meta's default processing.
27111
+ * Ignored by LinkedIn.
26746
27112
  *
26747
27113
  */
26748
27114
  consent?: {