@zernio/node 0.2.982 → 0.2.983

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
@@ -48579,6 +48579,10 @@ type UpdateTrackingTagData = {
48579
48579
  automaticMatchingFields?: Array<('em' | 'ph' | 'fn' | 'ln' | 'ge' | 'db' | 'ct' | 'st' | 'zp' | 'country' | 'external_id')>;
48580
48580
  firstPartyCookieStatus?: 'empty' | 'first_party_cookie_disabled' | 'first_party_cookie_enabled';
48581
48581
  dataUseSetting?: 'advertising_and_analytics' | 'analytics_only' | 'empty';
48582
+ /**
48583
+ * First-party cookie on or off (TikTok, LinkedIn). Platform-neutral alternative to `firstPartyCookieStatus`.
48584
+ */
48585
+ enableFirstPartyCookies?: boolean;
48582
48586
  /**
48583
48587
  * Google Ads: turn gclid auto-tagging on or off for the ad account.
48584
48588
  */
package/dist/index.d.ts CHANGED
@@ -48579,6 +48579,10 @@ type UpdateTrackingTagData = {
48579
48579
  automaticMatchingFields?: Array<('em' | 'ph' | 'fn' | 'ln' | 'ge' | 'db' | 'ct' | 'st' | 'zp' | 'country' | 'external_id')>;
48580
48580
  firstPartyCookieStatus?: 'empty' | 'first_party_cookie_disabled' | 'first_party_cookie_enabled';
48581
48581
  dataUseSetting?: 'advertising_and_analytics' | 'analytics_only' | 'empty';
48582
+ /**
48583
+ * First-party cookie on or off (TikTok, LinkedIn). Platform-neutral alternative to `firstPartyCookieStatus`.
48584
+ */
48585
+ enableFirstPartyCookies?: boolean;
48582
48586
  /**
48583
48587
  * Google Ads: turn gclid auto-tagging on or off for the ad account.
48584
48588
  */
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: "@zernio/node",
39
- version: "0.2.982",
39
+ version: "0.2.983",
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: "@zernio/node",
8
- version: "0.2.982",
8
+ version: "0.2.983",
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": "@zernio/node",
3
- "version": "0.2.982",
3
+ "version": "0.2.983",
4
4
  "description": "The official Node.js library for the Zernio API",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -13645,6 +13645,11 @@ export const startBusinessAgentEvalRun = <ThrowOnError extends boolean = false>(
13645
13645
  * connection can read (an ad account the user has no Business Access role on is skipped).
13646
13646
  * `id` equals `siteTagId`, the id the site loads with `pintrk('load', id)`.
13647
13647
  *
13648
+ * TikTok (platform `tiktokads`): TikTok Pixels across the connection's advertisers, or one
13649
+ * advertiser with `?adAccountId=<numeric advertiser_id>`. `id` is the numeric `pixel_id`,
13650
+ * `siteTagId` the alphanumeric `pixel_code` from Events Manager. Connections authorized
13651
+ * before the Pixel Management permission (about 2026-05-28) answer 403 until reconnected.
13652
+ *
13648
13653
  */
13649
13654
  export const listTrackingTags = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<ListTrackingTagsData, ThrowOnError>) => {
13650
13655
  return (options?.client ?? client).get<ListTrackingTagsResponse, ListTrackingTagsError, ThrowOnError>({
@@ -13703,6 +13708,10 @@ export const listTrackingTags = <ThrowOnError extends boolean = false>(options:
13703
13708
  * created, which is what switches Google's conversion tracking on, and
13704
13709
  * the tag is returned with it as its first event.
13705
13710
  *
13711
+ * TikTok: `POST /pixel/create/` on the advertiser in `adAccountId` (numeric). Names are at
13712
+ * most 40 characters with no emoji and must be unique; TikTok refuses a duplicate name
13713
+ * (400), which is its only retry guard. TikTok has no pixel delete API.
13714
+ *
13706
13715
  */
13707
13716
  export const createTrackingTag = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<CreateTrackingTagData, ThrowOnError>) => {
13708
13717
  return (options?.client ?? client).post<CreateTrackingTagResponse, CreateTrackingTagError, ThrowOnError>({
@@ -13736,6 +13745,10 @@ export const createTrackingTag = <ThrowOnError extends boolean = false>(options:
13736
13745
  * and `lastFiredTime`. Without `adAccountId` Zernio finds the ad account that owns the tag
13737
13746
  * (404 when no readable ad account holds it).
13738
13747
  *
13748
+ * TikTok: read from `/pixel/list/?pixel_id=`; `code` is TikTok's `pixel_script`, `events`
13749
+ * the pixel events. `lastFiredTime` is not available on TikTok. Without `adAccountId` the
13750
+ * connection's advertisers are searched.
13751
+ *
13739
13752
  */
13740
13753
  export const getTrackingTag = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<GetTrackingTagData, ThrowOnError>) => {
13741
13754
  return (options?.client ?? client).get<GetTrackingTagResponse, GetTrackingTagError, ThrowOnError>({
@@ -13777,6 +13790,12 @@ export const getTrackingTag = <ThrowOnError extends boolean = false>(options: Op
13777
13790
  * PATCH or PUT on `conversion_tags/{id}` answer 405 "Method not allowed". Set enhanced match
13778
13791
  * at creation (`automaticMatchingFields`) or change it and the name in Pinterest Ads Manager.
13779
13792
  *
13793
+ * TikTok: `name`, `enableAutomaticMatching` + `automaticMatchingFields` (folded onto
13794
+ * TikTok's five switches: em, ph, fn/ln, ct/st/zp/country, external_id; ge and db answer
13795
+ * 400), and first-party cookies via `enableFirstPartyCookies` or `firstPartyCookieStatus`
13796
+ * (enabled or disabled). TikTok has no pixel delete: the endpoint is absent from its API and
13797
+ * `POST /pixel/delete/` answers 404.
13798
+ *
13780
13799
  */
13781
13800
  export const updateTrackingTag = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<UpdateTrackingTagData, ThrowOnError>) => {
13782
13801
  return (options?.client ?? client).patch<UpdateTrackingTagResponse, UpdateTrackingTagError, ThrowOnError>({
@@ -13793,6 +13812,9 @@ export const updateTrackingTag = <ThrowOnError extends boolean = false>(options:
13793
13812
  * Insight Tag; the role (`FULL` or `USE_ONLY`) is appended to `name`. LinkedIn exposes
13794
13813
  * permissions per ad account only, so accounts the connection cannot see are not listed.
13795
13814
  *
13815
+ * TikTok (`tiktokads`): the advertisers linked to the pixel in its Business Center
13816
+ * (`/bc/pixel/link/get/`); a pixel outside Business Center answers 400.
13817
+ *
13796
13818
  */
13797
13819
  export const listTrackingTagSharedAccounts = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<ListTrackingTagSharedAccountsData, ThrowOnError>) => {
13798
13820
  return (options?.client ?? client).get<ListTrackingTagSharedAccountsResponse, ListTrackingTagSharedAccountsError, ThrowOnError>({
@@ -13814,6 +13836,11 @@ export const listTrackingTagSharedAccounts = <ThrowOnError extends boolean = fal
13814
13836
  * `adAccountId` is the numeric LinkedIn ad account id. An ad account uses one Insight Tag at
13815
13837
  * a time, so a target that already has one answers 400.
13816
13838
  *
13839
+ * TikTok: links the pixel to an advertiser through Business Center
13840
+ * (`/bc/pixel/link/update/`, `adAccountId` = numeric advertiser_id). Only a pixel that is an
13841
+ * asset of a Business Center this connection manages can be shared; otherwise the answer is
13842
+ * 400 asking to transfer it to Business Center first.
13843
+ *
13817
13844
  */
13818
13845
  export const addTrackingTagSharedAccount = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<AddTrackingTagSharedAccountData, ThrowOnError>) => {
13819
13846
  return (options?.client ?? client).post<AddTrackingTagSharedAccountResponse, AddTrackingTagSharedAccountError, ThrowOnError>({
@@ -13832,6 +13859,8 @@ export const addTrackingTagSharedAccount = <ThrowOnError extends boolean = false
13832
13859
  * revoking the last ad account that holds the tag: LinkedIn accepts that call and the tag
13833
13860
  * is orphaned (verified live).
13834
13861
  *
13862
+ * TikTok: unlinks through Business Center (`/bc/pixel/link/update/` with `UNLINK`).
13863
+ *
13835
13864
  */
13836
13865
  export const removeTrackingTagSharedAccount = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<RemoveTrackingTagSharedAccountData, ThrowOnError>) => {
13837
13866
  return (options?.client ?? client).delete<RemoveTrackingTagSharedAccountResponse, RemoveTrackingTagSharedAccountError, ThrowOnError>({
@@ -13993,6 +14022,10 @@ export const removeTrackingTagFromStore = <ThrowOnError extends boolean = false>
13993
14022
  * `event_name`. Standard events (`pagevisit`, `checkout`...) need no object and are not
13994
14023
  * listed.
13995
14024
  *
14025
+ * TikTok: the pixel's events from `/pixel/list/`. TikTok refreshes this list every 2 to 4
14026
+ * hours, so a just-created event can be missing. `siteEventId` is the `ttq.track()` name the
14027
+ * site fires.
14028
+ *
13996
14029
  */
13997
14030
  export const listTrackingTagEvents = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<ListTrackingTagEventsData, ThrowOnError>) => {
13998
14031
  return (options?.client ?? client).get<ListTrackingTagEventsResponse, ListTrackingTagEventsError, ThrowOnError>({
@@ -14058,6 +14091,13 @@ export const listTrackingTagEvents = <ThrowOnError extends boolean = false>(opti
14058
14091
  * VIEW_CATEGORY, VIEW_CONTENT, SEARCH, WATCH_VIDEO) or `siteEvent`. A duplicate name answers
14059
14092
  * 400.
14060
14093
  *
14094
+ * TikTok: `POST /pixel/event/create/`. `type` is a TikTok pixel event type (SHOPPING,
14095
+ * ON_WEB_CART, ON_WEB_DETAIL, INITIATE_ORDER, ADD_BILLING, ON_WEB_SEARCH, PAGE_VIEW,
14096
+ * ON_WEB_REGISTER, FORM, ...), or pass `siteEvent`. Stores `name` (at most 40 characters),
14097
+ * `defaultValue` and `currency` (USD, JPY or INR only). TikTok returns no id: the new event
14098
+ * is read back from the pixel, and while TikTok's listing has not refreshed the response
14099
+ * carries an empty `id` and `status: pending`.
14100
+ *
14061
14101
  */
14062
14102
  export const createTrackingTagEvent = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<CreateTrackingTagEventData, ThrowOnError>) => {
14063
14103
  return (options?.client ?? client).post<CreateTrackingTagEventResponse, CreateTrackingTagEventError, ThrowOnError>({
@@ -14089,6 +14129,9 @@ export const createTrackingTagEvent = <ThrowOnError extends boolean = false>(opt
14089
14129
  * Pinterest identifies the event by its name, so `name` cannot change (400): create the new
14090
14130
  * name and delete the old one.
14091
14131
  *
14132
+ * TikTok: `name`, `defaultValue` and `currency` (USD, JPY or INR); the type cannot change
14133
+ * (delete and recreate).
14134
+ *
14092
14135
  */
14093
14136
  export const updateTrackingTagEvent = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<UpdateTrackingTagEventData, ThrowOnError>) => {
14094
14137
  return (options?.client ?? client).patch<UpdateTrackingTagEventResponse, UpdateTrackingTagEventError, ThrowOnError>({
@@ -14120,6 +14163,9 @@ export const updateTrackingTagEvent = <ThrowOnError extends boolean = false>(opt
14120
14163
  * Pinterest (platform `pinterestads`): stops Pinterest tracking the event name (`state:
14121
14164
  * disabled`); Pinterest keeps the event's history.
14122
14165
  *
14166
+ * TikTok: hard delete (`/pixel/event/delete/`); TikTok refuses events bound to an ad group
14167
+ * (400).
14168
+ *
14123
14169
  */
14124
14170
  export const deleteTrackingTagEvent = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<DeleteTrackingTagEventData, ThrowOnError>) => {
14125
14171
  return (options?.client ?? client).delete<DeleteTrackingTagEventResponse, DeleteTrackingTagEventError, ThrowOnError>({
@@ -14240,6 +14286,11 @@ export const getTrackingTagDiagnostics = <ThrowOnError extends boolean = false>(
14240
14286
  * (ad-account level, not per tag; an account Pinterest cannot score yet carries `error`
14241
14287
  * instead). Pinterest has no time-bounded counts, so `startTime`/`endTime` answer 400.
14242
14288
  *
14289
+ * TikTok: per-event counts from `/pixel/event/stats/` (`total_count`,
14290
+ * `browser_event_total_count`, `server_event_total_count`, `attributed_count`,
14291
+ * `preview_count`), bucketed by UTC day. Defaults to the last 7 days; at most 30 days per
14292
+ * request. `aggregation` is not accepted.
14293
+ *
14243
14294
  */
14244
14295
  export const getTrackingTagStats = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<GetTrackingTagStatsData, ThrowOnError>) => {
14245
14296
  return (options?.client ?? client).get<GetTrackingTagStatsResponse, GetTrackingTagStatsError, ThrowOnError>({
@@ -49722,6 +49722,10 @@ export type UpdateTrackingTagData = {
49722
49722
  automaticMatchingFields?: Array<('em' | 'ph' | 'fn' | 'ln' | 'ge' | 'db' | 'ct' | 'st' | 'zp' | 'country' | 'external_id')>;
49723
49723
  firstPartyCookieStatus?: 'empty' | 'first_party_cookie_disabled' | 'first_party_cookie_enabled';
49724
49724
  dataUseSetting?: 'advertising_and_analytics' | 'analytics_only' | 'empty';
49725
+ /**
49726
+ * First-party cookie on or off (TikTok, LinkedIn). Platform-neutral alternative to `firstPartyCookieStatus`.
49727
+ */
49728
+ enableFirstPartyCookies?: boolean;
49725
49729
  /**
49726
49730
  * Google Ads: turn gclid auto-tagging on or off for the ad account.
49727
49731
  */