@koda-sl/baker-cli 0.430.0 → 0.431.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/README.md CHANGED
@@ -1462,7 +1462,7 @@ Shared flags: `--days <n>` (default 30) or `--start-date` / `--end-date` (`YYYY-
1462
1462
 
1463
1463
  **`tracking` answers "can this account be reported on at all", and it reads the ad account to do it.** `analytics ads` can only describe parameters that have already arrived, which leaves two blind spots that mislead in the expensive direction: a platform with no traffic in the window looks exactly like a platform whose ads carry nothing, and a dimension arriving under a name nobody has mapped looks exactly like one nothing carries. `baker analytics tracking` reads the mapping, the traffic **and** the client's own Google tracking templates / Meta URL parameters, so it can answer for a platform that has not had a click yet. Every dimension comes back in one of four states, and they are four different jobs: `covered` is done; `unmapped` means the URLs already carry it under a name Baker does not read, so run the `mapCommand` in the response — free, and it repairs the traffic already collected; `missing` means nothing carries it; `unknown` means no visit arrived *and* the account could not be read, which is not a finding and must never be reported as untagged.
1464
1464
 
1465
- **`fix` says which level to put the missing pairs at, and who can write it.** Not a field name — the levels that platform accepts tagging at, widest first (the widest is the one to prefer: it covers campaigns nobody has created yet), which of them Baker can stage and which the user has to do by hand, and how each field treats a value already in it. That last part is the one people skip and it differs per platform: a Google **campaign** final URL suffix *replaces* the account one rather than merging, LinkedIn's `url-params` call *sets the ad set's whole parameter set* and Baker cannot read back what is in it, and a Meta creative is immutable so a live ad cannot be retagged through Baker at all. `suffix` is only ever the **missing** pairs, so the rule everywhere is the same: read what is there, work out what is missing, write the union. Where `fix` says Baker has no write surface — Microsoft, TikTok, Reddit, Pinterest, Snapchat — that is a request to hand the user with the exact string and the exact screen, never a reason to stop on the platforms it can write.
1465
+ **`fix` says which level to put the missing pairs at, and who can write it.** Not a field name — the levels that platform accepts tagging at, widest first (the widest is the one to prefer: it covers campaigns nobody has created yet), which of them Baker can stage and which the user has to do by hand, and how each field treats a value already in it. That last part is the one people skip and it differs per platform: a Google **campaign** final URL suffix *replaces* the account one rather than merging, LinkedIn's `url-params` call *sets the ad set's whole parameter set* and Baker cannot read back what is in it, and a Meta creative is immutable so a live ad cannot be retagged through Baker at all. `suffix` is only ever the **missing** pairs, so the rule everywhere is the same: read what is there, work out what is missing, write the union. Where `fix` says Baker has no write surface — Microsoft, TikTok, Reddit, Pinterest, Snapchat — that is a request to hand the user with the exact string and the exact screen, never a reason to stop on the platforms it can write. ChatGPT Ads is one Baker can write: its campaign and ad group `--tracking-template` (`baker ads chatgpt campaigns|ad-groups update`), which should carry `campaign_id={campaign_id}&ad_group_id={ad_group_id}&ad_id={ad_id}` — an id that only rides in `utm_campaign` or `utm_content` is reported as that UTM and never as the campaign or the ad, so `--platform chatgpt --role adgroup_id` has nothing to split by.
1466
1466
 
1467
1467
  **The one recommendation about the ad account itself.** `baker analytics ads --platform <p>` warns when that platform's traffic carries no campaign id, ad group id or ad id — the three tiers every "which ad worked" question is grouped by — and returns the exact URL suffix, in the platform's own macro language, that would start sending the missing ones. It is the only mapping gap that cannot be fixed afterwards: naming a parameter Baker already captures corrects the history, because roles are resolved when a report is read, but a parameter the ads never sent has no stored values for a meaning to apply to. The hint stays quiet for a platform with little traffic, and defers to the untagged-account finding rather than repeating it.
1468
1468
 
package/dist/cli.js CHANGED
@@ -37858,7 +37858,7 @@ var SHARED_ARGS = {
37858
37858
  "max-bid": { type: "string", description: "Bid in account currency, e.g. 2.50 \u2014 fixed_bid only" },
37859
37859
  "tracking-template": {
37860
37860
  type: "string",
37861
- description: "Query string added to this ad group's landing pages, e.g. utm_content={ad_group_id} \u2014 none clears"
37861
+ description: "Query string added to this ad group's landing pages, e.g. ad_group_id={ad_group_id} \u2014 none clears"
37862
37862
  },
37863
37863
  "audience-bids": {
37864
37864
  type: "string",
@@ -38048,7 +38048,7 @@ var SHARED_ARGS2 = {
38048
38048
  },
38049
38049
  "tracking-template": {
38050
38050
  type: "string",
38051
- description: "Query string added to this card's landing page, e.g. utm_content={ad_id} \u2014 none clears"
38051
+ description: "Query string added to this card's landing page, e.g. ad_id={ad_id} \u2014 none clears"
38052
38052
  },
38053
38053
  status: { type: "string", description: "paused (default) | active" }
38054
38054
  };
@@ -38505,7 +38505,7 @@ var SHARED_ARGS3 = {
38505
38505
  },
38506
38506
  "tracking-template": {
38507
38507
  type: "string",
38508
- description: "Query string added to every landing page, e.g. utm_source=chatgpt&utm_campaign={campaign_id}&click_id={oppref} \u2014 none clears"
38508
+ description: "Query string added to every landing page, e.g. utm_source=chatgpt&utm_campaign={campaign_id}&campaign_id={campaign_id}&ad_group_id={ad_group_id}&ad_id={ad_id} \u2014 keep the ids under those names, which Baker analytics splits by; the oppref click id is added by ChatGPT Ads itself. none clears"
38509
38509
  },
38510
38510
  platforms: {
38511
38511
  type: "string",
@@ -44049,7 +44049,8 @@ var AD_PLATFORMS2 = [
44049
44049
  "tiktok",
44050
44050
  "reddit",
44051
44051
  "pinterest",
44052
- "snapchat"
44052
+ "snapchat",
44053
+ "chatgpt"
44053
44054
  ];
44054
44055
  function isAdPlatform(value2) {
44055
44056
  return AD_PLATFORMS2.includes(value2);
@@ -44236,6 +44237,16 @@ var SNAPCHAT = {
44236
44237
  { role: "ad_name", macro: "{{creative.name}}", names: ["ad_name", "creative_name"] }
44237
44238
  ]
44238
44239
  };
44240
+ var CHATGPT = {
44241
+ platform: "chatgpt",
44242
+ label: "ChatGPT Ads",
44243
+ docs: "https://help.openai.com/en/articles/20001212-create-ads-for-chatgpt",
44244
+ dimensions: [
44245
+ { role: "campaign_id", macro: "{campaign_id}", names: ["campaign_id", "campaignid"] },
44246
+ { role: "adgroup_id", macro: "{ad_group_id}", names: ["ad_group_id", "adgroup_id"] },
44247
+ { role: "ad_id", macro: "{ad_id}", names: ["ad_id", "adid"] }
44248
+ ]
44249
+ };
44239
44250
  var AD_PLATFORM_DEFINITIONS = {
44240
44251
  google: GOOGLE,
44241
44252
  meta: META,
@@ -44244,7 +44255,8 @@ var AD_PLATFORM_DEFINITIONS = {
44244
44255
  tiktok: TIKTOK,
44245
44256
  reddit: REDDIT,
44246
44257
  pinterest: PINTEREST,
44247
- snapchat: SNAPCHAT
44258
+ snapchat: SNAPCHAT,
44259
+ chatgpt: CHATGPT
44248
44260
  };
44249
44261
  var ESSENTIAL_ROLES = ["campaign_id", "adgroup_id", "ad_id", "keyword", "match_type"];
44250
44262
  function essentialAdDimensions(platform) {
@@ -65222,7 +65234,7 @@ var SHARED_ARGS4 = {
65222
65234
  },
65223
65235
  platform: {
65224
65236
  type: "string",
65225
- description: "Read the whole report in one ad platform's vocabulary, and from its traffic only: google, meta, microsoft, linkedin, tiktok, reddit, pinterest, snapchat. Two effects at once \u2014 --role resolves against the spellings that platform uses (`cid` is TikTok's ad and nobody else's campaign) and the report narrows to the visits that arrived from it. Start here when comparing platforms, because without it every dimension is the union across all of them and one parameter can land under two roles",
65237
+ description: "Read the whole report in one ad platform's vocabulary, and from its traffic only: google, meta, microsoft, linkedin, tiktok, reddit, pinterest, snapchat, chatgpt. Two effects at once \u2014 --role resolves against the spellings that platform uses (`cid` is TikTok's ad and nobody else's campaign) and the report narrows to the visits that arrived from it. Start here when comparing platforms, because without it every dimension is the union across all of them and one parameter can land under two roles",
65226
65238
  required: false
65227
65239
  },
65228
65240
  origin: {
@@ -65678,7 +65690,7 @@ var mapCommand = (() => {
65678
65690
  const args8 = {
65679
65691
  platform: {
65680
65692
  type: "string",
65681
- description: "Which platform these parameters belong to: google, meta, microsoft, linkedin, tiktok, reddit, pinterest, snapchat. REQUIRED with --set or --remove, because there is no such thing as a parameter that means one thing everywhere \u2014 `cid` is TikTok's ad and everyone else's campaign, and Meta cannot send a keyword at all. Leave it off only to read the whole mapping back",
65693
+ description: "Which platform these parameters belong to: google, meta, microsoft, linkedin, tiktok, reddit, pinterest, snapchat, chatgpt. REQUIRED with --set or --remove, because there is no such thing as a parameter that means one thing everywhere \u2014 `cid` is TikTok's ad and everyone else's campaign, and Meta cannot send a keyword at all. Leave it off only to read the whole mapping back",
65682
65694
  required: false
65683
65695
  },
65684
65696
  set: {
@@ -65722,7 +65734,7 @@ var trackingCommand = (() => {
65722
65734
  const args8 = {
65723
65735
  platform: {
65724
65736
  type: "string",
65725
- description: "One platform: google, meta, microsoft, linkedin, tiktok, reddit, pinterest, snapchat. Omit to check the ones worth checking \u2014 every platform sending visits, plus Google and Meta, whose accounts Baker can read directly",
65737
+ description: "One platform: google, meta, microsoft, linkedin, tiktok, reddit, pinterest, snapchat, chatgpt. Omit to check the ones worth checking \u2014 every platform sending visits, plus Google and Meta, whose accounts Baker can read directly",
65726
65738
  required: false
65727
65739
  },
65728
65740
  days: { type: "string", description: "Lookback window for the traffic half (default: 30)", required: false }