@koda-sl/baker-cli 0.234.0 → 0.235.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/cli.js CHANGED
@@ -108,7 +108,7 @@ import {
108
108
  } from "./chunk-DZUVUGEP.js";
109
109
 
110
110
  // src/cli.ts
111
- import { defineCommand as defineCommand225, runMain } from "citty";
111
+ import { defineCommand as defineCommand226, runMain } from "citty";
112
112
 
113
113
  // src/cache-flag.ts
114
114
  var NO_CACHE_ARG = {
@@ -7679,7 +7679,7 @@ Full guide: __tooling__/docs/tools/baker/actions.md`
7679
7679
  });
7680
7680
 
7681
7681
  // src/commands/ads/index.ts
7682
- import { defineCommand as defineCommand86 } from "citty";
7682
+ import { defineCommand as defineCommand87 } from "citty";
7683
7683
 
7684
7684
  // src/commands/ads/google/index.ts
7685
7685
  import { defineCommand as defineCommand31 } from "citty";
@@ -16554,7 +16554,7 @@ Full guide: __tooling__/docs/tools/baker/ads-linkedin.md`
16554
16554
  });
16555
16555
 
16556
16556
  // src/commands/ads/meta/index.ts
16557
- import { defineCommand as defineCommand68 } from "citty";
16557
+ import { defineCommand as defineCommand69 } from "citty";
16558
16558
 
16559
16559
  // src/commands/ads/meta/account.ts
16560
16560
  import { defineCommand as defineCommand52 } from "citty";
@@ -16698,6 +16698,13 @@ import { defineCommand as defineCommand55 } from "citty";
16698
16698
  // src/commands/ads/meta/write-shared.ts
16699
16699
  import { readFileSync as readFileSync8 } from "fs";
16700
16700
 
16701
+ // ../api/src/ads-meta/leadAds.ts
16702
+ var META_LEAD_ADS_NOT_ENABLED_MESSAGE = "Reading Meta instant forms and their leads is not switched on for this company. Everything else on Meta keeps working. Tell the user this needs switching on by the Baker team, and carry on with the rest of the job.";
16703
+ var META_LEAD_ADS_RECONNECT_MESSAGE = "This Meta connection was made before lead ads were switched on for this company, so it cannot work with instant forms or read their leads. Ask the user to reconnect Meta in the dashboard \u2014 that grants the extra permissions \u2014 then ask for this again. Everything else on Meta keeps working meanwhile.";
16704
+ function isMetaLeadAdsRefusal(message) {
16705
+ return message === META_LEAD_ADS_NOT_ENABLED_MESSAGE || message === META_LEAD_ADS_RECONNECT_MESSAGE;
16706
+ }
16707
+
16701
16708
  // ../api/src/ads-meta/limits.ts
16702
16709
  var META_LIMITS = {
16703
16710
  campaign: {
@@ -19069,9 +19076,177 @@ Async is automatic for heavy queries; pass --async to force it, or --no-async to
19069
19076
  }
19070
19077
  });
19071
19078
 
19072
- // src/commands/ads/meta/media.ts
19079
+ // src/commands/ads/meta/leads.ts
19073
19080
  import { defineCommand as defineCommand64 } from "citty";
19074
- var metaMediaCommand = defineCommand64({
19081
+ registerSchema({
19082
+ command: "ads.meta.lead-forms",
19083
+ description: "List the instant (lead) forms on a Facebook Page, with how many leads each has collected. Start here: a lead is fetched by form id, and `baker ads meta pages` gives the page id.",
19084
+ args: {
19085
+ "page-id": { type: "string", description: "Facebook Page ID \u2014 from `baker ads meta pages`", required: true },
19086
+ full: { type: "boolean", description: "Include each form's questions", required: false },
19087
+ output: { type: "string", description: "json|csv", required: false, default: "json" }
19088
+ }
19089
+ });
19090
+ registerSchema({
19091
+ command: "ads.meta.leads",
19092
+ description: "Read the leads an instant form collected. Contact details (email, phone) come back masked; pass --full only when the raw values are genuinely needed, e.g. handing them to a CRM.",
19093
+ args: {
19094
+ "form-id": { type: "string", description: "Instant form ID \u2014 from `baker ads meta lead-forms`", required: false },
19095
+ "ad-id": { type: "string", description: "Read the leads of one ad instead of a whole form", required: false },
19096
+ since: { type: "string", description: "Earliest submission date, YYYY-MM-DD", required: false },
19097
+ until: { type: "string", description: "Latest submission date, YYYY-MM-DD (inclusive)", required: false },
19098
+ limit: { type: "string", description: "Leads per page (default 100, max 500)", required: false },
19099
+ after: {
19100
+ type: "string",
19101
+ description: "Cursor from a previous call's nextCursor \u2014 fetches the following page",
19102
+ required: false
19103
+ },
19104
+ full: { type: "boolean", description: "Return raw contact details instead of masked ones", required: false },
19105
+ output: { type: "string", description: "json|csv", required: false, default: "json" }
19106
+ }
19107
+ });
19108
+ var LEAD_FORMS_CAP = 500;
19109
+ function leadFormHints(forms) {
19110
+ if (forms.length === 0) {
19111
+ return ["This Page has NO instant forms. Nothing to read leads from \u2014 the form has to be created first."];
19112
+ }
19113
+ if (forms.length >= LEAD_FORMS_CAP) {
19114
+ return [
19115
+ `PARTIAL LIST \u2014 this Page has at least ${LEAD_FORMS_CAP} instant forms and only the first ${LEAD_FORMS_CAP} came back. Do not describe this as every form on the Page.`
19116
+ ];
19117
+ }
19118
+ const empty = forms.filter((form) => (form.leads_count ?? 0) === 0);
19119
+ if (empty.length === forms.length) {
19120
+ return [
19121
+ "Every form on this Page has collected 0 leads. That is a real, readable answer \u2014 the connection works. Do not retry and do not report it as a permissions problem."
19122
+ ];
19123
+ }
19124
+ return [];
19125
+ }
19126
+ function handleLeadsError(err) {
19127
+ if (err instanceof ApiError && err.code === "FORBIDDEN" && isMetaLeadAdsRefusal(err.message)) {
19128
+ writeAdsJson({
19129
+ ok: false,
19130
+ error: {
19131
+ code: err.code,
19132
+ message: err.message,
19133
+ fix: { action: "reject", explanation: err.message },
19134
+ retryable: false
19135
+ }
19136
+ });
19137
+ process.exit(1);
19138
+ }
19139
+ handleMetaError(err);
19140
+ }
19141
+ function leadPageHints(page, full) {
19142
+ const hints = [];
19143
+ if (page.nextCursor) {
19144
+ hints.push(
19145
+ `PARTIAL PAGE \u2014 more leads exist. This is ${page.leads.length} of an unknown larger number; do NOT report it as a total. Fetch the next page with \`--after ${page.nextCursor}\` (repeat until no nextCursor), or narrow the window with --since/--until.`
19146
+ );
19147
+ }
19148
+ if (!full) {
19149
+ hints.push(
19150
+ "Email and phone answers are masked. Report on them as they are; pass --full only when the raw values have to leave Baker (a CRM hand-off), and never paste them into the chat otherwise."
19151
+ );
19152
+ }
19153
+ return hints;
19154
+ }
19155
+ var leadFormsCommand2 = defineCommand64({
19156
+ meta: {
19157
+ name: "lead-forms",
19158
+ description: `List the instant (lead) forms on a Facebook Page, with each form's lead count. A lead is read by form id, so start here \u2014 get the Page id from \`baker ads meta pages\`.
19159
+
19160
+ Examples:
19161
+ baker ads meta lead-forms --page-id 100635183117758
19162
+ baker ads meta lead-forms --page-id 100635183117758 --full # also lists each form's questions`
19163
+ },
19164
+ args: {
19165
+ "page-id": { type: "string", description: "Facebook Page ID" },
19166
+ full: { type: "boolean", description: "Include each form's questions" },
19167
+ output: { type: "string", description: "Output format", default: "json" }
19168
+ },
19169
+ run: async ({ args }) => {
19170
+ try {
19171
+ const pageId = args["page-id"];
19172
+ if (!pageId) {
19173
+ handleLeadsError(new Error("--page-id is required. Run `baker ads meta pages` to find it."));
19174
+ }
19175
+ const params = { "page-id": pageId };
19176
+ if (args.full) params.full = "true";
19177
+ const data = await apiGet("/api/ads/meta/lead-forms", params);
19178
+ const fmt = csvOrJson(args);
19179
+ if (fmt !== "json") {
19180
+ writeAdsOutput(data, fmt);
19181
+ return;
19182
+ }
19183
+ const hints = leadFormHints(data);
19184
+ writeJsonEnvelope(hints.length > 0 ? { ok: true, data, hints } : { ok: true, data });
19185
+ } catch (err) {
19186
+ handleLeadsError(err);
19187
+ }
19188
+ }
19189
+ });
19190
+ var leadsCommand2 = defineCommand64({
19191
+ meta: {
19192
+ name: "leads",
19193
+ description: `Read the leads an instant form collected. Every question comes back; email and phone answers are MASKED unless you pass --full, so you can report on what a form is collecting without moving contact details around.
19194
+
19195
+ Examples:
19196
+ baker ads meta leads --form-id 987654321
19197
+ baker ads meta leads --form-id 987654321 --since 2026-08-01 --until 2026-08-31
19198
+ baker ads meta leads --ad-id 6123456789 --limit 50
19199
+ baker ads meta leads --form-id 987654321 --after <nextCursor> # the next page
19200
+ baker ads meta leads --form-id 987654321 --full # raw contact details \u2014 only when handing leads over
19201
+
19202
+ Results are PAGED. A response carrying \`nextCursor\` is not the whole set \u2014 follow it before reporting any total.`
19203
+ },
19204
+ args: {
19205
+ "form-id": { type: "string", description: "Instant form ID (from `baker ads meta lead-forms`)" },
19206
+ "ad-id": { type: "string", description: "Read one ad's leads instead of a whole form" },
19207
+ since: { type: "string", description: "Earliest submission date, YYYY-MM-DD" },
19208
+ until: { type: "string", description: "Latest submission date, YYYY-MM-DD (inclusive)" },
19209
+ limit: { type: "string", description: "Leads per page (default 100, max 500)" },
19210
+ after: { type: "string", description: "Cursor from a previous call's nextCursor" },
19211
+ full: { type: "boolean", description: "Return raw contact details instead of masked ones" },
19212
+ output: { type: "string", description: "Output format", default: "json" }
19213
+ },
19214
+ run: async ({ args }) => {
19215
+ try {
19216
+ const formId = args["form-id"];
19217
+ const adId = args["ad-id"];
19218
+ if (!formId && !adId) {
19219
+ handleLeadsError(new Error("Pass --form-id (from `baker ads meta lead-forms`) or --ad-id."));
19220
+ }
19221
+ const params = {};
19222
+ if (formId) params["form-id"] = formId;
19223
+ if (adId) params["ad-id"] = adId;
19224
+ if (args.since) params.since = args.since;
19225
+ if (args.until) params.until = args.until;
19226
+ if (args.limit) params.limit = String(args.limit);
19227
+ if (args.after) params.after = String(args.after);
19228
+ if (args.full) params.full = "true";
19229
+ const page = await apiGet("/api/ads/meta/leads", params);
19230
+ const fmt = csvOrJson(args);
19231
+ if (fmt !== "json") {
19232
+ writeAdsOutput(page.leads, fmt);
19233
+ return;
19234
+ }
19235
+ writeJsonEnvelope({
19236
+ ok: true,
19237
+ data: page.leads,
19238
+ ...page.nextCursor ? { nextCursor: page.nextCursor } : {},
19239
+ hints: leadPageHints(page, args.full === true)
19240
+ });
19241
+ } catch (err) {
19242
+ handleLeadsError(err);
19243
+ }
19244
+ }
19245
+ });
19246
+
19247
+ // src/commands/ads/meta/media.ts
19248
+ import { defineCommand as defineCommand65 } from "citty";
19249
+ var metaMediaCommand = defineCommand65({
19075
19250
  meta: {
19076
19251
  name: "media",
19077
19252
  description: "Stage Baker library media uploads to Meta so creatives can reference them. Subcommand: upload. Publishes an ad-image hash or video id a creative binds via --image-ref/--video-ref."
@@ -19080,7 +19255,7 @@ var metaMediaCommand = defineCommand64({
19080
19255
  });
19081
19256
 
19082
19257
  // src/commands/ads/meta/pages.ts
19083
- import { defineCommand as defineCommand65 } from "citty";
19258
+ import { defineCommand as defineCommand66 } from "citty";
19084
19259
  function advertisablePages(data) {
19085
19260
  return data.filter((p) => Array.isArray(p.tasks) && p.tasks.includes("ADVERTISE"));
19086
19261
  }
@@ -19098,7 +19273,7 @@ function pageSelectionHints(data) {
19098
19273
  }
19099
19274
  return [];
19100
19275
  }
19101
- var pagesCommand = defineCommand65({
19276
+ var pagesCommand = defineCommand66({
19102
19277
  meta: {
19103
19278
  name: "pages",
19104
19279
  description: `List the Facebook Pages the connected user manages. Every Meta ad publishes from a Page, so use this to identify the Page an ad should run from. The 'tasks' field shows what the user can do on each Page (ADVERTISE means it can back ads). If exactly one Page can ADVERTISE, use it; if more than one can, confirm with the user which Page to use; if none can, ask the user to grant Advertise access \u2014 a wrong or non-advertising Page publishes under the wrong brand identity.
@@ -19129,8 +19304,8 @@ Examples:
19129
19304
  });
19130
19305
 
19131
19306
  // src/commands/ads/meta/pixels.ts
19132
- import { defineCommand as defineCommand66 } from "citty";
19133
- var pixelsCommand = defineCommand66({
19307
+ import { defineCommand as defineCommand67 } from "citty";
19308
+ var pixelsCommand = defineCommand67({
19134
19309
  meta: {
19135
19310
  name: "pixels",
19136
19311
  description: `List Meta Pixels for an ad account, or fetch firing stats for one pixel.
@@ -19212,7 +19387,7 @@ function emit(data, args, warnings = []) {
19212
19387
 
19213
19388
  // src/commands/ads/meta/preview.ts
19214
19389
  import { writeFileSync as writeFileSync2 } from "fs";
19215
- import { defineCommand as defineCommand67 } from "citty";
19390
+ import { defineCommand as defineCommand68 } from "citty";
19216
19391
  var VALID_AD_FORMATS = [
19217
19392
  "DESKTOP_FEED_STANDARD",
19218
19393
  "MOBILE_FEED_STANDARD",
@@ -19274,7 +19449,7 @@ function listPlacements() {
19274
19449
  const instagram = Object.keys(INSTAGRAM_PREVIEW_FORMATS).join(", ");
19275
19450
  return `facebook \u2014 ${facebook}; instagram \u2014 ${instagram}`;
19276
19451
  }
19277
- var previewCommand2 = defineCommand67({
19452
+ var previewCommand2 = defineCommand68({
19278
19453
  meta: {
19279
19454
  name: "preview",
19280
19455
  description: `Generate a Meta-hosted preview iframe for a creative or ad. Returns iframe HTML which you
@@ -19353,7 +19528,7 @@ Examples:
19353
19528
  });
19354
19529
 
19355
19530
  // src/commands/ads/meta/index.ts
19356
- var metaCommand = defineCommand68({
19531
+ var metaCommand = defineCommand69({
19357
19532
  meta: {
19358
19533
  name: "meta",
19359
19534
  description: `Meta Marketing API \u2014 AI-first command surface (Facebook + Instagram ads).
@@ -19363,6 +19538,8 @@ Discovery:
19363
19538
  baker ads meta accounts --include-all \u2014 every account the token can see
19364
19539
  baker ads meta businesses \u2014 Business Manager IDs
19365
19540
  baker ads meta pages \u2014 Facebook Pages the user manages (an ad's identity)
19541
+ baker ads meta lead-forms --page-id 100635183117758 \u2014 instant (lead) forms on a Page, with lead counts
19542
+ baker ads meta leads --form-id 987654321 \u2014 the leads one form collected (contact details masked)
19366
19543
 
19367
19544
  Snapshot a running account (default = ACTIVE only):
19368
19545
  baker ads meta campaigns --account-id act_123
@@ -19395,6 +19572,8 @@ Full guide: __tooling__/docs/tools/baker/ads-meta.md`
19395
19572
  account: accountCommand2,
19396
19573
  businesses: businessesCommand,
19397
19574
  pages: pagesCommand,
19575
+ "lead-forms": leadFormsCommand2,
19576
+ leads: leadsCommand2,
19398
19577
  campaigns: campaignsCommand3,
19399
19578
  adsets: adsetsCommand,
19400
19579
  ads: adsListCommand,
@@ -19410,10 +19589,10 @@ Full guide: __tooling__/docs/tools/baker/ads-meta.md`
19410
19589
  });
19411
19590
 
19412
19591
  // src/commands/ads/x/index.ts
19413
- import { defineCommand as defineCommand85 } from "citty";
19592
+ import { defineCommand as defineCommand86 } from "citty";
19414
19593
 
19415
19594
  // src/commands/ads/x/accounts.ts
19416
- import { defineCommand as defineCommand69 } from "citty";
19595
+ import { defineCommand as defineCommand70 } from "citty";
19417
19596
  registerSchema({
19418
19597
  command: "ads.x.accounts",
19419
19598
  description: "List the X Ads accounts this company connected \u2014 there can be several, and every one of them is yours to work in. Returns accounts with id (base36), name, approval_status, timezone, currency. Run this first to find account IDs for other commands.",
@@ -19450,7 +19629,7 @@ function handleAccountsError2(err) {
19450
19629
  writeAdsJson({ ok: false, error: { code: "NETWORK_ERROR", message: "Unexpected error" } });
19451
19630
  process.exit(1);
19452
19631
  }
19453
- var accountsCommand4 = defineCommand69({
19632
+ var accountsCommand4 = defineCommand70({
19454
19633
  meta: {
19455
19634
  name: "accounts",
19456
19635
  description: `List accessible X Ads accounts. Returns account IDs needed for all other commands.
@@ -19490,7 +19669,7 @@ Examples:
19490
19669
  });
19491
19670
 
19492
19671
  // src/commands/ads/x/active-entities.ts
19493
- import { defineCommand as defineCommand70 } from "citty";
19672
+ import { defineCommand as defineCommand71 } from "citty";
19494
19673
 
19495
19674
  // src/commands/ads/x/error-parser.ts
19496
19675
  function mapXErrorCode(message) {
@@ -19641,7 +19820,7 @@ function parseCsv(v) {
19641
19820
  const parts = v.split(",").map((s) => s.trim()).filter(Boolean);
19642
19821
  return parts.length > 0 ? parts : void 0;
19643
19822
  }
19644
- var activeEntitiesCommand = defineCommand70({
19823
+ var activeEntitiesCommand = defineCommand71({
19645
19824
  meta: {
19646
19825
  name: "active-entities",
19647
19826
  description: `List entities with metric activity in a time range.
@@ -19699,7 +19878,7 @@ Examples:
19699
19878
  });
19700
19879
 
19701
19880
  // src/commands/ads/x/audiences.ts
19702
- import { defineCommand as defineCommand71 } from "citty";
19881
+ import { defineCommand as defineCommand72 } from "citty";
19703
19882
  registerSchema({
19704
19883
  command: "ads.x.audiences",
19705
19884
  description: "List custom audiences for an X Ads account. Returns id, name, audience_size, audience_type, targetable status. Audiences need 100+ active users in the past 90 days to be targetable.",
@@ -19709,7 +19888,7 @@ registerSchema({
19709
19888
  output: { type: "string", description: "Format: json|csv|md", required: false, default: "json" }
19710
19889
  }
19711
19890
  });
19712
- var audiencesCommand4 = defineCommand71({
19891
+ var audiencesCommand4 = defineCommand72({
19713
19892
  meta: {
19714
19893
  name: "audiences",
19715
19894
  description: `List X Ads custom audiences.
@@ -19758,7 +19937,7 @@ Examples:
19758
19937
  });
19759
19938
 
19760
19939
  // src/commands/ads/x/campaigns.ts
19761
- import { defineCommand as defineCommand72 } from "citty";
19940
+ import { defineCommand as defineCommand73 } from "citty";
19762
19941
 
19763
19942
  // src/commands/ads/x/run-list.ts
19764
19943
  function buildCleanParams(opts) {
@@ -19822,7 +20001,7 @@ registerSchema({
19822
20001
  output: { type: "string", description: "Format: json|csv|md", required: false, default: "json" }
19823
20002
  }
19824
20003
  });
19825
- var campaignsCommand4 = defineCommand72({
20004
+ var campaignsCommand4 = defineCommand73({
19826
20005
  meta: {
19827
20006
  name: "campaigns",
19828
20007
  description: `List X Ads campaigns. Returns budget, schedule, funding instrument, status.
@@ -19864,7 +20043,7 @@ Examples:
19864
20043
  });
19865
20044
 
19866
20045
  // src/commands/ads/x/cards.ts
19867
- import { defineCommand as defineCommand73 } from "citty";
20046
+ import { defineCommand as defineCommand74 } from "citty";
19868
20047
  registerSchema({
19869
20048
  command: "ads.x.cards",
19870
20049
  description: "List website cards, video cards, and carousels for an X Ads account.",
@@ -19874,7 +20053,7 @@ registerSchema({
19874
20053
  output: { type: "string", description: "Format: json|csv|md", required: false, default: "json" }
19875
20054
  }
19876
20055
  });
19877
- var cardsCommand = defineCommand73({
20056
+ var cardsCommand = defineCommand74({
19878
20057
  meta: {
19879
20058
  name: "cards",
19880
20059
  description: `List X Ads cards (rich creatives).
@@ -19923,7 +20102,7 @@ Examples:
19923
20102
  });
19924
20103
 
19925
20104
  // src/commands/ads/x/funding.ts
19926
- import { defineCommand as defineCommand74 } from "citty";
20105
+ import { defineCommand as defineCommand75 } from "citty";
19927
20106
  registerSchema({
19928
20107
  command: "ads.x.funding",
19929
20108
  description: "List funding instruments for an X Ads account. Returns id, type, currency, credit_limit_local_micro, funded_amount_local_micro, status. Falls back to BAKER_X_ADS_ACCOUNT_ID env var.",
@@ -19933,7 +20112,7 @@ registerSchema({
19933
20112
  output: { type: "string", description: "Format: json|csv|md", required: false, default: "json" }
19934
20113
  }
19935
20114
  });
19936
- var fundingCommand = defineCommand74({
20115
+ var fundingCommand = defineCommand75({
19937
20116
  meta: {
19938
20117
  name: "funding",
19939
20118
  description: `List funding instruments for an X Ads account.
@@ -19982,7 +20161,7 @@ Examples:
19982
20161
  });
19983
20162
 
19984
20163
  // src/commands/ads/x/line-items.ts
19985
- import { defineCommand as defineCommand75 } from "citty";
20164
+ import { defineCommand as defineCommand76 } from "citty";
19986
20165
  registerSchema({
19987
20166
  command: "ads.x.lineItems",
19988
20167
  description: "List line items (ad groups) for an X Ads account. Returns bid, product_type, objective, placements, schedule. Filter by campaign-ids or line-item-ids (CSV).",
@@ -19994,7 +20173,7 @@ registerSchema({
19994
20173
  "no-cache": { type: "boolean", description: "Skip cache", required: false }
19995
20174
  }
19996
20175
  });
19997
- var lineItemsCommand = defineCommand75({
20176
+ var lineItemsCommand = defineCommand76({
19998
20177
  meta: {
19999
20178
  name: "line-items",
20000
20179
  description: `List X Ads line items (ad groups).
@@ -20035,7 +20214,7 @@ Examples:
20035
20214
  });
20036
20215
 
20037
20216
  // src/commands/ads/x/media.ts
20038
- import { defineCommand as defineCommand76 } from "citty";
20217
+ import { defineCommand as defineCommand77 } from "citty";
20039
20218
  registerSchema({
20040
20219
  command: "ads.x.media",
20041
20220
  description: "List media assets in the X Ads media library (images, GIFs, videos). Filter by media-type (IMAGE, GIF, VIDEO).",
@@ -20046,7 +20225,7 @@ registerSchema({
20046
20225
  output: { type: "string", description: "Format: json|csv|md", required: false, default: "json" }
20047
20226
  }
20048
20227
  });
20049
- var mediaCommand = defineCommand76({
20228
+ var mediaCommand = defineCommand77({
20050
20229
  meta: {
20051
20230
  name: "media",
20052
20231
  description: `List media assets in the X Ads media library.
@@ -20098,7 +20277,7 @@ Examples:
20098
20277
  });
20099
20278
 
20100
20279
  // src/commands/ads/x/promoted-tweets.ts
20101
- import { defineCommand as defineCommand77 } from "citty";
20280
+ import { defineCommand as defineCommand78 } from "citty";
20102
20281
  registerSchema({
20103
20282
  command: "ads.x.promotedTweets",
20104
20283
  description: "List promoted tweets for an X Ads account. Returns id, line_item_id, tweet_id, approval_status. Filter by line-item-ids (CSV).",
@@ -20109,7 +20288,7 @@ registerSchema({
20109
20288
  "no-cache": { type: "boolean", description: "Skip cache", required: false }
20110
20289
  }
20111
20290
  });
20112
- var promotedTweetsCommand = defineCommand77({
20291
+ var promotedTweetsCommand = defineCommand78({
20113
20292
  meta: {
20114
20293
  name: "promoted-tweets",
20115
20294
  description: `List X Ads promoted tweets.
@@ -20163,11 +20342,11 @@ Examples:
20163
20342
  });
20164
20343
 
20165
20344
  // src/commands/ads/x/stats/index.ts
20166
- import { defineCommand as defineCommand82 } from "citty";
20345
+ import { defineCommand as defineCommand83 } from "citty";
20167
20346
 
20168
20347
  // src/commands/ads/x/stats/job.ts
20169
20348
  import { gunzipSync } from "zlib";
20170
- import { defineCommand as defineCommand78 } from "citty";
20349
+ import { defineCommand as defineCommand79 } from "citty";
20171
20350
  var POLL_INTERVAL_MS2 = 1e4;
20172
20351
  var DEADLINE_MS = 12 * 60 * 1e3;
20173
20352
  var RESULT_CACHE_TTL_MS = 6 * 60 * 60 * 1e3;
@@ -20237,7 +20416,7 @@ async function pollUntilDone(accountId, jobId) {
20237
20416
  function buildCacheKey(body) {
20238
20417
  return `stats-job:${JSON.stringify(body)}`;
20239
20418
  }
20240
- var statsJobCommand = defineCommand78({
20419
+ var statsJobCommand = defineCommand79({
20241
20420
  meta: {
20242
20421
  name: "job",
20243
20422
  description: `Async X Ads stats job, sync from the CLI's perspective. Creates \u2192 polls \u2192 downloads \u2192 returns.
@@ -20342,7 +20521,7 @@ For fine-grained control (don't wait, poll yourself), use:
20342
20521
  });
20343
20522
 
20344
20523
  // src/commands/ads/x/stats/job-create.ts
20345
- import { defineCommand as defineCommand79 } from "citty";
20524
+ import { defineCommand as defineCommand80 } from "citty";
20346
20525
  registerSchema({
20347
20526
  command: "ads.x.statsJobCreate",
20348
20527
  description: "Create an asynchronous X Ads stats job (range up to 90 days non-segmented, 45 days segmented). Returns a job id; poll with `stats job-status`. Times must be ISO 8601 hour-aligned.",
@@ -20365,7 +20544,7 @@ function parseCsv3(v) {
20365
20544
  const parts = v.split(",").map((s) => s.trim()).filter(Boolean);
20366
20545
  return parts.length > 0 ? parts : void 0;
20367
20546
  }
20368
- var statsJobCreateCommand = defineCommand79({
20547
+ var statsJobCreateCommand = defineCommand80({
20369
20548
  meta: {
20370
20549
  name: "job-create",
20371
20550
  description: `Create an async X Ads stats job (up to 90 days, supports segmentation).
@@ -20428,7 +20607,7 @@ Examples:
20428
20607
  });
20429
20608
 
20430
20609
  // src/commands/ads/x/stats/job-status.ts
20431
- import { defineCommand as defineCommand80 } from "citty";
20610
+ import { defineCommand as defineCommand81 } from "citty";
20432
20611
  registerSchema({
20433
20612
  command: "ads.x.statsJobStatus",
20434
20613
  description: "Check the status of one or more X Ads stats jobs. Returns status (PROCESSING|SUCCESS|FAILED) and a downloadable url when SUCCESS. Pass --job-id or --job-ids (CSV).",
@@ -20438,7 +20617,7 @@ registerSchema({
20438
20617
  "job-ids": { type: "string", description: "CSV of job IDs", required: false }
20439
20618
  }
20440
20619
  });
20441
- var statsJobStatusCommand = defineCommand80({
20620
+ var statsJobStatusCommand = defineCommand81({
20442
20621
  meta: {
20443
20622
  name: "job-status",
20444
20623
  description: `Poll the status of an async X Ads stats job.
@@ -20479,7 +20658,7 @@ Examples:
20479
20658
  });
20480
20659
 
20481
20660
  // src/commands/ads/x/stats/sync.ts
20482
- import { defineCommand as defineCommand81 } from "citty";
20661
+ import { defineCommand as defineCommand82 } from "citty";
20483
20662
 
20484
20663
  // src/commands/ads/x/presets.ts
20485
20664
  var X_STATS_PRESETS = [
@@ -20638,7 +20817,7 @@ async function runSync(args, q) {
20638
20817
  process.exit(1);
20639
20818
  }
20640
20819
  }
20641
- var statsSyncCommand = defineCommand81({
20820
+ var statsSyncCommand = defineCommand82({
20642
20821
  meta: {
20643
20822
  name: "sync",
20644
20823
  description: `Synchronous X Ads analytics (max 7-day window).
@@ -20681,7 +20860,7 @@ Examples:
20681
20860
  });
20682
20861
 
20683
20862
  // src/commands/ads/x/stats/index.ts
20684
- var statsCommand = defineCommand82({
20863
+ var statsCommand = defineCommand83({
20685
20864
  meta: {
20686
20865
  name: "stats",
20687
20866
  description: `X Ads analytics. Sync (\u22647 days, no segmentation) or async jobs (\u226490 days, segmentable).
@@ -20709,7 +20888,7 @@ Examples:
20709
20888
  });
20710
20889
 
20711
20890
  // src/commands/ads/x/targeting-constants.ts
20712
- import { defineCommand as defineCommand83 } from "citty";
20891
+ import { defineCommand as defineCommand84 } from "citty";
20713
20892
  var ALLOWED_CONSTANTS = [
20714
20893
  "locations",
20715
20894
  "interests",
@@ -20737,7 +20916,7 @@ registerSchema({
20737
20916
  "no-cache": { type: "boolean", description: "Skip cache", required: false }
20738
20917
  }
20739
20918
  });
20740
- var targetingConstantsCommand = defineCommand83({
20919
+ var targetingConstantsCommand = defineCommand84({
20741
20920
  meta: {
20742
20921
  name: "targeting-constants",
20743
20922
  description: `Lookup X Ads targeting constants.
@@ -20787,7 +20966,7 @@ Examples:
20787
20966
  });
20788
20967
 
20789
20968
  // src/commands/ads/x/targeting-criteria.ts
20790
- import { defineCommand as defineCommand84 } from "citty";
20969
+ import { defineCommand as defineCommand85 } from "citty";
20791
20970
  registerSchema({
20792
20971
  command: "ads.x.targetingCriteria",
20793
20972
  description: "List targeting criteria attached to line items in an X Ads account. Returns targeting_type, targeting_value, name, operator_type per criterion. Filter by line-item-ids.",
@@ -20797,7 +20976,7 @@ registerSchema({
20797
20976
  "no-cache": { type: "boolean", description: "Skip cache", required: false }
20798
20977
  }
20799
20978
  });
20800
- var targetingCriteriaCommand = defineCommand84({
20979
+ var targetingCriteriaCommand = defineCommand85({
20801
20980
  meta: {
20802
20981
  name: "targeting-criteria",
20803
20982
  description: `List targeting criteria attached to line items.
@@ -20848,7 +21027,7 @@ Examples:
20848
21027
  });
20849
21028
 
20850
21029
  // src/commands/ads/x/index.ts
20851
- var xCommand = defineCommand85({
21030
+ var xCommand = defineCommand86({
20852
21031
  meta: {
20853
21032
  name: "x",
20854
21033
  description: `X (Twitter) Ads commands. Read campaigns, line items, promoted tweets, creatives, audiences, and analytics.
@@ -20887,7 +21066,7 @@ Full guide: __tooling__/docs/tools/baker/ads-x.md`
20887
21066
  });
20888
21067
 
20889
21068
  // src/commands/ads/index.ts
20890
- var adsCommand2 = defineCommand86({
21069
+ var adsCommand2 = defineCommand87({
20891
21070
  meta: {
20892
21071
  name: "ads",
20893
21072
  description: `Ad platform commands. Each platform exposes its own native command surface \u2014 no forced parity.
@@ -20918,10 +21097,10 @@ Full guides: __tooling__/docs/tools/baker/ads-<platform>.md (google|meta|linkedi
20918
21097
  });
20919
21098
 
20920
21099
  // src/commands/avatars/index.ts
20921
- import { defineCommand as defineCommand92 } from "citty";
21100
+ import { defineCommand as defineCommand93 } from "citty";
20922
21101
 
20923
21102
  // src/commands/avatars/create.ts
20924
- import { defineCommand as defineCommand87 } from "citty";
21103
+ import { defineCommand as defineCommand88 } from "citty";
20925
21104
 
20926
21105
  // src/commands/avatars/casting.ts
20927
21106
  var VERBATIM_RULE = "Copy `subjectDescription` into the prompt VERBATIM, word for word. Re-phrasing it per generation is the other reason a face drifts across a set \u2014 treat it as an identifier that happens to read as prose.";
@@ -21188,7 +21367,7 @@ registerSchema({
21188
21367
  "voice-description": { type: "string", description: "How the voice should sound", required: false }
21189
21368
  }
21190
21369
  });
21191
- var createCommand2 = defineCommand87({
21370
+ var createCommand2 = defineCommand88({
21192
21371
  meta: {
21193
21372
  name: "create",
21194
21373
  description: 'Cast a new avatar (reusable AI presenter). Example: baker avatars create --name "Marta" --subject "woman in her early 40s, shoulder-length dark hair, light olive skin, warm open face" --persona "friendly product expert". Returns while the identity sheet is still building.'
@@ -21269,7 +21448,7 @@ var createCommand2 = defineCommand87({
21269
21448
  });
21270
21449
 
21271
21450
  // src/commands/avatars/delete.ts
21272
- import { defineCommand as defineCommand88 } from "citty";
21451
+ import { defineCommand as defineCommand89 } from "citty";
21273
21452
  registerSchema({
21274
21453
  command: "avatars.delete",
21275
21454
  description: "Remove an avatar. Prefer --archive: it retires the avatar so it stops showing in the roster and must not be cast again, while past work and @handle mentions still resolve. Without --archive the avatar is gone for good and the mention resolves nowhere. Confirm with the user first \u2014 this is their cast, and it is not yours to retire. --dry-run previews.",
@@ -21284,7 +21463,7 @@ registerSchema({
21284
21463
  "dry-run": { type: "boolean", description: "Preview without removing anything", required: false, default: false }
21285
21464
  }
21286
21465
  });
21287
- var deleteCommand = defineCommand88({
21466
+ var deleteCommand = defineCommand89({
21288
21467
  meta: {
21289
21468
  name: "delete",
21290
21469
  description: "Remove an avatar. Prefer --archive (retire, past work still resolves) over a hard delete. Example: baker avatars delete marta --archive --dry-run"
@@ -21318,7 +21497,7 @@ var deleteCommand = defineCommand88({
21318
21497
  });
21319
21498
 
21320
21499
  // src/commands/avatars/get.ts
21321
- import { defineCommand as defineCommand89 } from "citty";
21500
+ import { defineCommand as defineCommand90 } from "citty";
21322
21501
  registerSchema({
21323
21502
  command: "avatars.get",
21324
21503
  description: "Read one avatar by handle \u2014 the command you run before casting it. Returns its status (only `ready` can be cast), the identity sheet URL every render must be grounded on via --reference, and the subject description that goes into the prompt VERBATIM. Add --full for the whole written profile (persona, speech, motion, wardrobe, setting, guardrails, voice, source photos).",
@@ -21332,7 +21511,7 @@ registerSchema({
21332
21511
  }
21333
21512
  }
21334
21513
  });
21335
- var getCommand2 = defineCommand89({
21514
+ var getCommand2 = defineCommand90({
21336
21515
  meta: {
21337
21516
  name: "get",
21338
21517
  description: "Read one avatar by handle: status, identity sheet URL for --reference, and the subject description to reuse verbatim. Example: baker avatars get marta --full"
@@ -21373,7 +21552,7 @@ var getCommand2 = defineCommand89({
21373
21552
  });
21374
21553
 
21375
21554
  // src/commands/avatars/list.ts
21376
- import { defineCommand as defineCommand90 } from "citty";
21555
+ import { defineCommand as defineCommand91 } from "citty";
21377
21556
  var STATUSES = ["generating", "ready", "error", "archived"];
21378
21557
  registerSchema({
21379
21558
  command: "avatars.list",
@@ -21388,7 +21567,7 @@ registerSchema({
21388
21567
  limit: { type: "number", description: "Max avatars to return (1-100)", required: false }
21389
21568
  }
21390
21569
  });
21391
- var listCommand10 = defineCommand90({
21570
+ var listCommand10 = defineCommand91({
21392
21571
  meta: {
21393
21572
  name: "list",
21394
21573
  description: "List the company's avatars (reusable AI presenters). Only `ready` ones can be cast. Example: baker avatars list --status ready --output md"
@@ -21422,7 +21601,7 @@ var listCommand10 = defineCommand90({
21422
21601
  });
21423
21602
 
21424
21603
  // src/commands/avatars/update.ts
21425
- import { defineCommand as defineCommand91 } from "citty";
21604
+ import { defineCommand as defineCommand92 } from "citty";
21426
21605
  function readUpdateArgs(args) {
21427
21606
  const handle = (args.handle || args["avatar-handle"])?.trim();
21428
21607
  if (!handle) {
@@ -21483,7 +21662,7 @@ registerSchema({
21483
21662
  }
21484
21663
  }
21485
21664
  });
21486
- var updateCommand2 = defineCommand91({
21665
+ var updateCommand2 = defineCommand92({
21487
21666
  meta: {
21488
21667
  name: "update",
21489
21668
  description: 'Edit an avatar; profile flags merge over what is stored. Example: baker avatars update marta --subject "woman in her early 50s, silver bob" --regenerate-sheet'
@@ -21546,7 +21725,7 @@ var updateCommand2 = defineCommand91({
21546
21725
  });
21547
21726
 
21548
21727
  // src/commands/avatars/index.ts
21549
- var avatarsCommand = defineCommand92({
21728
+ var avatarsCommand = defineCommand93({
21550
21729
  meta: {
21551
21730
  name: "avatars",
21552
21731
  description: `Reusable AI presenters this company can cast into images and video. An avatar holds one settled identity, so the same face can carry a whole campaign. Subcommands: list, get, create, update, delete.
@@ -21576,12 +21755,12 @@ Full guide: __tooling__/docs/tools/baker/avatars.md`
21576
21755
  });
21577
21756
 
21578
21757
  // src/commands/brand/index.ts
21579
- import { defineCommand as defineCommand94 } from "citty";
21758
+ import { defineCommand as defineCommand95 } from "citty";
21580
21759
 
21581
21760
  // src/commands/brand/fonts.ts
21582
21761
  import { mkdir, readdir, readFile as readFile2, writeFile } from "fs/promises";
21583
21762
  import path2 from "path";
21584
- import { defineCommand as defineCommand93 } from "citty";
21763
+ import { defineCommand as defineCommand94 } from "citty";
21585
21764
 
21586
21765
  // src/engine/brand/fonts.ts
21587
21766
  import { posix } from "path";
@@ -22425,7 +22604,7 @@ async function unresolvedAction(css, unresolved) {
22425
22604
  }
22426
22605
  return `Run \`baker brand fonts fetch "${unresolved[0]}"\` to self-host it, which writes the @font-face for you. For a face no catalogue carries, add an @font-face pointing at a file in ${FONTS_DIR}.`;
22427
22606
  }
22428
- var fontsCheckCommand = defineCommand93({
22607
+ var fontsCheckCommand = defineCommand94({
22429
22608
  meta: {
22430
22609
  name: "check",
22431
22610
  description: "Verify the brand's fonts really exist. First: every --font-* family in src/styles/global.css must be provided by a local @font-face, or it renders as a fallback on every page \u2014 a Google @import does not provide one here, the build drops it before the page loads. Then, for families still requested from Google, ask Google what it actually serves \u2014 a weight nobody serves is silently synthesized."
@@ -22477,7 +22656,7 @@ var fontsCheckCommand = defineCommand93({
22477
22656
  });
22478
22657
  }
22479
22658
  });
22480
- var fontsFetchCommand = defineCommand93({
22659
+ var fontsFetchCommand = defineCommand94({
22481
22660
  meta: {
22482
22661
  name: "fetch",
22483
22662
  description: "Download a font from Google Fonts or Fontsource into src/brand/fonts/ and write its @font-face into src/styles/global.css above @theme, so the family actually loads. Use when a brand font should be self-hosted rather than requested from a third party on every page load."
@@ -22578,7 +22757,7 @@ async function astroSources() {
22578
22757
  }
22579
22758
  return out;
22580
22759
  }
22581
- var fontsAdoptCommand = defineCommand93({
22760
+ var fontsAdoptCommand = defineCommand94({
22582
22761
  meta: {
22583
22762
  name: "adopt",
22584
22763
  description: "Move brand faces a page already self-hosts into src/styles/global.css, so every page loads them instead of just that one. Use when `check` reports a family as not loaded but the font files are already in src/brand/fonts/ \u2014 downloading it again would hand that page a different build of the same face."
@@ -22658,7 +22837,7 @@ var fontsAdoptCommand = defineCommand93({
22658
22837
  });
22659
22838
  }
22660
22839
  });
22661
- var fontsCommand = defineCommand93({
22840
+ var fontsCommand = defineCommand94({
22662
22841
  meta: {
22663
22842
  name: "fonts",
22664
22843
  description: `Verify and self-host the brand's typefaces.
@@ -22678,7 +22857,7 @@ Subcommands:
22678
22857
  });
22679
22858
 
22680
22859
  // src/commands/brand/index.ts
22681
- var brandCommand = defineCommand94({
22860
+ var brandCommand = defineCommand95({
22682
22861
  meta: {
22683
22862
  name: "brand",
22684
22863
  description: `Brand asset verification for src/brand/.
@@ -22694,11 +22873,11 @@ Subcommands:
22694
22873
  });
22695
22874
 
22696
22875
  // src/commands/canvas/index.ts
22697
- import { defineCommand as defineCommand105 } from "citty";
22876
+ import { defineCommand as defineCommand106 } from "citty";
22698
22877
 
22699
22878
  // src/commands/canvas/catalog.ts
22700
- import { defineCommand as defineCommand95 } from "citty";
22701
- var catalogCommand = defineCommand95({
22879
+ import { defineCommand as defineCommand96 } from "citty";
22880
+ var catalogCommand = defineCommand96({
22702
22881
  meta: {
22703
22882
  name: "catalog",
22704
22883
  description: "Print the agent-facing node catalog (JSON Schema). Includes every registered node grouped by category."
@@ -22713,7 +22892,7 @@ var catalogCommand = defineCommand95({
22713
22892
  // src/commands/canvas/critique.ts
22714
22893
  import { readFile as readFile3 } from "fs/promises";
22715
22894
  import path3 from "path";
22716
- import { defineCommand as defineCommand96 } from "citty";
22895
+ import { defineCommand as defineCommand97 } from "citty";
22717
22896
 
22718
22897
  // src/engine/scaffold/lib/critique.ts
22719
22898
  var VIBE_CUE = /\b(light|lighting|golden|moody|warm|cool|tone|grade|contrast|shadow|glow|rim|backlit|neon|soft)\b/i;
@@ -22833,7 +23012,7 @@ function critiqueCanvas(canvas) {
22833
23012
  }
22834
23013
 
22835
23014
  // src/commands/canvas/critique.ts
22836
- var critiqueCommand = defineCommand96({
23015
+ var critiqueCommand = defineCommand97({
22837
23016
  meta: {
22838
23017
  name: "critique",
22839
23018
  description: "Pre-spend creative critic (ADVISORY \u2014 never blocks). Scores a scaffolded creative BEFORE the billed render, so weak spots get fixed for free. A VIDEO creative is scored on hook strength, sound-off first-frame legibility, retention risk, and mechanism clarity; a STATIC ad on baked-text legibility risk, identity grounding, brand-type fidelity, and mechanism clarity. Ground a video hook against `baker winning-ads hooks` for a proven pattern."
@@ -22875,9 +23054,9 @@ import { execFile } from "child_process";
22875
23054
  import { readdir as readdir2, readFile as readFile4, stat } from "fs/promises";
22876
23055
  import path4 from "path";
22877
23056
  import { promisify } from "util";
22878
- import { defineCommand as defineCommand97 } from "citty";
23057
+ import { defineCommand as defineCommand98 } from "citty";
22879
23058
  var execFileAsync = promisify(execFile);
22880
- var inspectCommand = defineCommand97({
23059
+ var inspectCommand = defineCommand98({
22881
23060
  meta: {
22882
23061
  name: "inspect",
22883
23062
  description: "Dump a one-page summary of a canvas run: per-node duration + cache status, list of output files in the run dir, and optionally three thumbnail frames per video output. Pass either a run_id (resolved against --outputs-dir) or an absolute run directory."
@@ -22985,12 +23164,12 @@ async function probeDuration(filePath) {
22985
23164
 
22986
23165
  // src/commands/canvas/rerun.ts
22987
23166
  import path16 from "path";
22988
- import { defineCommand as defineCommand99 } from "citty";
23167
+ import { defineCommand as defineCommand100 } from "citty";
22989
23168
 
22990
23169
  // src/commands/canvas/run.ts
22991
23170
  import { readFile as readFile11 } from "fs/promises";
22992
23171
  import path15 from "path";
22993
- import { defineCommand as defineCommand98 } from "citty";
23172
+ import { defineCommand as defineCommand99 } from "citty";
22994
23173
 
22995
23174
  // src/commands/canvas/normalize-paths.ts
22996
23175
  import { existsSync as existsSync3, realpathSync } from "fs";
@@ -27241,7 +27420,7 @@ async function restoreRunSnapshot(manifest, targetDir, opts = {}) {
27241
27420
  }
27242
27421
 
27243
27422
  // src/commands/canvas/run.ts
27244
- var runCommand = defineCommand98({
27423
+ var runCommand = defineCommand99({
27245
27424
  meta: { name: "run", description: "Validate and execute a canvas JSON file." },
27246
27425
  args: {
27247
27426
  file: { type: "positional", required: true, description: "Path to canvas JSON" },
@@ -27621,7 +27800,7 @@ async function postInitialRunRecord(client, payload) {
27621
27800
 
27622
27801
  // src/commands/canvas/rerun.ts
27623
27802
  var SLUG_PATTERN = /^[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/;
27624
- var rerunCommand = defineCommand99({
27803
+ var rerunCommand = defineCommand100({
27625
27804
  meta: {
27626
27805
  name: "rerun",
27627
27806
  description: "Re-run a creative's latest recorded canvas. Restores its definition files from run history first, so it works in a fresh workspace that never had the source chat's files \u2014 an interrupted run resumes (in-flight jobs re-attach), a completed one re-renders from the cache."
@@ -27718,7 +27897,7 @@ async function fetchManifest(url) {
27718
27897
  // src/commands/canvas/scaffold-static-ad.ts
27719
27898
  import { access, mkdir as mkdir6, readFile as readFile13, writeFile as writeFile8 } from "fs/promises";
27720
27899
  import path20 from "path";
27721
- import { defineCommand as defineCommand101 } from "citty";
27900
+ import { defineCommand as defineCommand102 } from "citty";
27722
27901
 
27723
27902
  // src/engine/scaffold/staticAd.ts
27724
27903
  import { z as z26 } from "zod";
@@ -28068,7 +28247,7 @@ function isValidScaffoldSlug(slug) {
28068
28247
  // src/commands/canvas/sync-definition.ts
28069
28248
  import { readdir as readdir6, readFile as readFile12, stat as stat3 } from "fs/promises";
28070
28249
  import path19 from "path";
28071
- import { defineCommand as defineCommand100 } from "citty";
28250
+ import { defineCommand as defineCommand101 } from "citty";
28072
28251
 
28073
28252
  // src/commands/canvas/definition-graph.ts
28074
28253
  var MAX_NODES = 300;
@@ -28181,7 +28360,7 @@ async function resolveCanvasPath(inputPath) {
28181
28360
  const chosen = (slug ? canvases.find((name) => name === `${slug}.canvas.json`) : void 0) ?? canvases[0];
28182
28361
  return chosen ? path19.join(dir, chosen) : null;
28183
28362
  }
28184
- var syncDefinitionCommand = defineCommand100({
28363
+ var syncDefinitionCommand = defineCommand101({
28185
28364
  meta: {
28186
28365
  name: "sync-definition",
28187
28366
  description: "Push a creative's current node-graph + input thumbnails to the dashboard without rendering. Runs automatically when you edit a creative's canvas.json or prompt.json."
@@ -28411,7 +28590,7 @@ async function runVisionPasses(canvas) {
28411
28590
  return fail3("read_outputs", e instanceof Error ? e.message : String(e));
28412
28591
  }
28413
28592
  }
28414
- var scaffoldStaticAdCommand = defineCommand101({
28593
+ var scaffoldStaticAdCommand = defineCommand102({
28415
28594
  meta: {
28416
28595
  name: "scaffold-static-ad",
28417
28596
  description: "Turn a source/inspiration image into a runnable static-ad canvas. Runs billed passes \u2014 image_describe (the blueprint, baked to prompt.json as the editable 'prompt'), an AI selection of the image's MAIN identity elements, and a structured global-layout pass (the column/row grid with per-region bounds and text sizes) \u2014 then scaffolds a canvas that wires one [TODO] ingest slot per element (logo/product/subject/badge + brand font) into image_generate. By default it also fans the hero out to the platform's placement ratios (via image_aspect_adapt \u2014 the hero ratio is free, the rest are billed AI recompositions); pass --placements none for a single base ad, or a preset to pick the set. Edit prompt.json and drop the real assets, then `baker canvas run` it."
@@ -28600,7 +28779,7 @@ var scaffoldStaticAdCommand = defineCommand101({
28600
28779
  import { access as access2, cp, mkdir as mkdir7, readFile as readFile16, rm as rm6, writeFile as writeFile9 } from "fs/promises";
28601
28780
  import { tmpdir as tmpdir2 } from "os";
28602
28781
  import path23 from "path";
28603
- import { defineCommand as defineCommand102 } from "citty";
28782
+ import { defineCommand as defineCommand103 } from "citty";
28604
28783
 
28605
28784
  // src/engine/scaffold/lib/model-router.ts
28606
28785
  var SEEDANCE = "bytedance/seedance-2.0";
@@ -29061,7 +29240,7 @@ async function runAnalysisPasses(deconstructCanvas, selectModel) {
29061
29240
  return fail4("deconstruct", e instanceof Error ? e.message : String(e));
29062
29241
  }
29063
29242
  }
29064
- var scaffoldVideoCommand = defineCommand102({
29243
+ var scaffoldVideoCommand = defineCommand103({
29065
29244
  meta: {
29066
29245
  name: "scaffold-video",
29067
29246
  description: "Turn a reference video into a runnable reproduction canvas in one command. Runs billed passes \u2014 video_deconstruct (the full scene-by-scene blueprint + transcript, baked to a split, editable blueprint: a global prompt.json plus one small scenes/sNN.json per scene) and an AI selection of the video's RECURRING identity elements (person/animal/product/logo) \u2014 then scaffolds a pipeline where every scene boundary is a static-ad-grade frame (the blueprint as target_blueprint, a reference legend, the real frame as anchor) and each recurring element gets ONE shared [TODO] ingest slot wired into every frame it appears in. The clips feed Seedance an ultra-detailed motion brief (action, camera, dialogue, transcript). Edit a scene's scenes/sNN.json (or prompt.json for global cast/palette/brand), drop the real source images, then `baker canvas run`."
@@ -29371,7 +29550,7 @@ var scaffoldVideoCommand = defineCommand102({
29371
29550
  // src/commands/canvas/set-prompt.ts
29372
29551
  import { readFile as readFile17, writeFile as writeFile10 } from "fs/promises";
29373
29552
  import path24 from "path";
29374
- import { defineCommand as defineCommand103 } from "citty";
29553
+ import { defineCommand as defineCommand104 } from "citty";
29375
29554
  function setNodePrompt(canvas, nodeId, text2) {
29376
29555
  const nodes = canvas?.nodes;
29377
29556
  if (!Array.isArray(nodes)) throw new Error("canvas has no nodes array");
@@ -29386,7 +29565,7 @@ function setNodePrompt(canvas, nodeId, text2) {
29386
29565
  newNodes[idx] = newNode;
29387
29566
  return { ...canvas, nodes: newNodes };
29388
29567
  }
29389
- var setPromptCommand = defineCommand103({
29568
+ var setPromptCommand = defineCommand104({
29390
29569
  meta: {
29391
29570
  name: "set-prompt",
29392
29571
  description: "Safely set a node's params.prompt (a frame description, motion prompt, etc.) without hand-editing the JSON. Prefer --text-file for multi-line/accented copy \u2014 it preserves UTF-8 exactly, unlike shell-quoted jq."
@@ -29446,8 +29625,8 @@ var setPromptCommand = defineCommand103({
29446
29625
  // src/commands/canvas/validate.ts
29447
29626
  import { readFile as readFile18 } from "fs/promises";
29448
29627
  import path25 from "path";
29449
- import { defineCommand as defineCommand104 } from "citty";
29450
- var validateCommand = defineCommand104({
29628
+ import { defineCommand as defineCommand105 } from "citty";
29629
+ var validateCommand = defineCommand105({
29451
29630
  meta: {
29452
29631
  name: "validate",
29453
29632
  description: "Validate a canvas JSON file (no execution). Includes a per-node cost preview and runs each node's deep validators (composition meta checks for hyperframe_render/_snapshot)."
@@ -29520,7 +29699,7 @@ var validateCommand = defineCommand104({
29520
29699
  });
29521
29700
 
29522
29701
  // src/commands/canvas/index.ts
29523
- var canvasCommand = defineCommand105({
29702
+ var canvasCommand = defineCommand106({
29524
29703
  meta: {
29525
29704
  name: "canvas",
29526
29705
  description: `Run Baker creative canvas JSON files locally. Local nodes execute in-process; remote nodes POST to the Convex backend gateway.
@@ -29554,7 +29733,7 @@ Full guide: __tooling__/docs/tools/baker/canvas.md`
29554
29733
  });
29555
29734
 
29556
29735
  // src/commands/capabilities/index.ts
29557
- import { defineCommand as defineCommand106 } from "citty";
29736
+ import { defineCommand as defineCommand107 } from "citty";
29558
29737
  registerSchema({
29559
29738
  command: "capabilities",
29560
29739
  description: "Start here, before promising the user anything on an ad platform, in Analytics, or in Tag Manager. Answers three questions in one call: what is connected and with what access, what a write on each surface actually does when it lands, and what CANNOT be done here and why. Run it with no arguments for every surface; name one surface to also get the exact fields every change on it accepts.",
@@ -29597,7 +29776,7 @@ function capabilityHints(surfaces) {
29597
29776
  }
29598
29777
  return hints;
29599
29778
  }
29600
- var runCapabilities = defineCommand106({
29779
+ var runCapabilities = defineCommand107({
29601
29780
  meta: {
29602
29781
  name: "capabilities",
29603
29782
  description: `What Baker can and cannot do for this company, before any work starts.
@@ -29653,7 +29832,7 @@ Full guide: __tooling__/docs/tools/baker/capabilities.md`
29653
29832
  var capabilitiesCommand = runCapabilities;
29654
29833
 
29655
29834
  // src/commands/chats/index.ts
29656
- import { defineCommand as defineCommand107 } from "citty";
29835
+ import { defineCommand as defineCommand108 } from "citty";
29657
29836
  var STATUS_GROUPS = ["active", "archived", "all"];
29658
29837
  var REPO_SURFACES = ["knowledge", "company", "brand", "landings", "flows", "creatives"];
29659
29838
  function parseBoundedInt(raw, name, min, max) {
@@ -29675,7 +29854,7 @@ registerSchema({
29675
29854
  full: { type: "boolean", description: "Include each Session's full change list", required: false, default: false }
29676
29855
  }
29677
29856
  });
29678
- var listCommand11 = defineCommand107({
29857
+ var listCommand11 = defineCommand108({
29679
29858
  meta: { name: "list", description: "List other Sessions on this account, newest first." },
29680
29859
  args: {
29681
29860
  status: { type: "string", description: "Filter: active|archived|all (default: all)", required: false },
@@ -29730,7 +29909,7 @@ registerSchema({
29730
29909
  }
29731
29910
  }
29732
29911
  });
29733
- var viewCommand = defineCommand107({
29912
+ var viewCommand = defineCommand108({
29734
29913
  meta: {
29735
29914
  name: "view",
29736
29915
  description: "Inspect one Session's full effects \u2014 git content + actions/tags/ads, kickoff, commits."
@@ -29774,7 +29953,7 @@ registerSchema({
29774
29953
  }
29775
29954
  }
29776
29955
  });
29777
- var transcriptCommand = defineCommand107({
29956
+ var transcriptCommand = defineCommand108({
29778
29957
  meta: { name: "transcript", description: "Read another Session's conversation." },
29779
29958
  args: {
29780
29959
  id: { type: "positional", description: "The Session id", required: true },
@@ -29826,7 +30005,7 @@ registerSchema({
29826
30005
  }
29827
30006
  }
29828
30007
  });
29829
- var diffCommand = defineCommand107({
30008
+ var diffCommand = defineCommand108({
29830
30009
  meta: { name: "diff", description: "See a published Session's real file-level changes." },
29831
30010
  args: {
29832
30011
  id: { type: "positional", description: "The Session id", required: true },
@@ -29870,7 +30049,7 @@ var diffCommand = defineCommand107({
29870
30049
  }
29871
30050
  }
29872
30051
  });
29873
- var chatsCommand = defineCommand107({
30052
+ var chatsCommand = defineCommand108({
29874
30053
  meta: {
29875
30054
  name: "chats",
29876
30055
  description: `Inspect other Sessions on this account (read-only): list them, view what they produced, read their conversation, and see their real file changes \u2014 so you can reuse past work for a new goal.
@@ -29885,10 +30064,10 @@ Full guide: __tooling__/docs/tools/baker/chats.md`
29885
30064
  });
29886
30065
 
29887
30066
  // src/commands/creatives/index.ts
29888
- import { defineCommand as defineCommand109 } from "citty";
30067
+ import { defineCommand as defineCommand110 } from "citty";
29889
30068
 
29890
30069
  // src/commands/creatives/publish.ts
29891
- import { defineCommand as defineCommand108 } from "citty";
30070
+ import { defineCommand as defineCommand109 } from "citty";
29892
30071
 
29893
30072
  // src/commands/images/api.ts
29894
30073
  import { readFile as readFile19 } from "fs/promises";
@@ -30035,7 +30214,7 @@ async function publishCreative(args, deps = defaultImageApiDeps) {
30035
30214
  chatId: chatIdFromEnv2()
30036
30215
  });
30037
30216
  }
30038
- var publishCommand = defineCommand108({
30217
+ var publishCommand = defineCommand109({
30039
30218
  meta: {
30040
30219
  name: "publish",
30041
30220
  description: "Publish a final static creative image to Baker Creatives and print the creative reference JSON."
@@ -30093,7 +30272,7 @@ var publishCommand = defineCommand108({
30093
30272
  });
30094
30273
 
30095
30274
  // src/commands/creatives/index.ts
30096
- var creativesCommand3 = defineCommand109({
30275
+ var creativesCommand3 = defineCommand110({
30097
30276
  meta: {
30098
30277
  name: "creatives",
30099
30278
  description: `Publish static ad creatives as first-class Baker outputs.
@@ -30110,11 +30289,11 @@ Full guide: __tooling__/docs/tools/baker/creatives.md`
30110
30289
  });
30111
30290
 
30112
30291
  // src/commands/flows/index.ts
30113
- import { defineCommand as defineCommand114 } from "citty";
30292
+ import { defineCommand as defineCommand115 } from "citty";
30114
30293
 
30115
30294
  // src/commands/flows/add.ts
30116
30295
  import { randomUUID } from "crypto";
30117
- import { defineCommand as defineCommand110 } from "citty";
30296
+ import { defineCommand as defineCommand111 } from "citty";
30118
30297
 
30119
30298
  // src/commands/flows/shared.ts
30120
30299
  import { existsSync as existsSync5, readdirSync as readdirSync2, readFileSync as readFileSync9, writeFileSync as writeFileSync3 } from "fs";
@@ -30324,7 +30503,7 @@ registerSchema({
30324
30503
  parent: { type: "string", description: "Parent node id. Omit to append to the root's children.", required: false }
30325
30504
  }
30326
30505
  });
30327
- var addNodeCommand = defineCommand110({
30506
+ var addNodeCommand = defineCommand111({
30328
30507
  meta: {
30329
30508
  name: "add-node",
30330
30509
  description: 'Add a step to a form, with the skeleton its type requires. Example: baker flows add-node contact --type customForm --name "Contact Info"'
@@ -30420,7 +30599,7 @@ registerSchema({
30420
30599
  }
30421
30600
  }
30422
30601
  });
30423
- var addSideEffectCommand = defineCommand110({
30602
+ var addSideEffectCommand = defineCommand111({
30424
30603
  meta: {
30425
30604
  name: "add-side-effect",
30426
30605
  description: "Add a side effect to a step, with the skeleton its type requires. Example: baker flows add-side-effect contact --node <id> --type googleSpreadsheet"
@@ -30502,7 +30681,7 @@ var addSideEffectCommand = defineCommand110({
30502
30681
 
30503
30682
  // src/commands/flows/map.ts
30504
30683
  import { readFileSync as readFileSync11 } from "fs";
30505
- import { defineCommand as defineCommand111 } from "citty";
30684
+ import { defineCommand as defineCommand112 } from "citty";
30506
30685
 
30507
30686
  // src/commands/flows/value-expression.ts
30508
30687
  import { existsSync as existsSync6, readFileSync as readFileSync10 } from "fs";
@@ -31275,7 +31454,7 @@ async function mapOptions(args, fromFile, into) {
31275
31454
  destinationFields: hubspotForm ? await hubspotFieldCatalog(hubspotForm) : void 0
31276
31455
  };
31277
31456
  }
31278
- var mapCommand = defineCommand111({
31457
+ var mapCommand = defineCommand112({
31279
31458
  meta: {
31280
31459
  name: "map",
31281
31460
  description: "Map form fields onto any value a side effect sends \u2014 never hand-write a mapping. Start here: baker flows map contact --from map.json --write"
@@ -31373,7 +31552,7 @@ var mapCommand = defineCommand111({
31373
31552
  });
31374
31553
 
31375
31554
  // src/commands/flows/normalize.ts
31376
- import { defineCommand as defineCommand112 } from "citty";
31555
+ import { defineCommand as defineCommand113 } from "citty";
31377
31556
  var OPTIONAL_STRINGS = ["oauthProviderId"];
31378
31557
  var ARRAY_FIELDS = [
31379
31558
  "fieldMapping",
@@ -31442,7 +31621,7 @@ registerSchema({
31442
31621
  }
31443
31622
  }
31444
31623
  });
31445
- var normalizeCommand = defineCommand112({
31624
+ var normalizeCommand = defineCommand113({
31446
31625
  meta: {
31447
31626
  name: "normalize",
31448
31627
  description: "Repair the shapes a form file is allowed to get slightly wrong. Example: baker flows normalize contact --write"
@@ -31473,7 +31652,7 @@ var normalizeCommand = defineCommand112({
31473
31652
  });
31474
31653
 
31475
31654
  // src/commands/flows/schema.ts
31476
- import { defineCommand as defineCommand113 } from "citty";
31655
+ import { defineCommand as defineCommand114 } from "citty";
31477
31656
  registerSchema({
31478
31657
  command: "flows.schema",
31479
31658
  description: "The shape of one node or side-effect type: a pasteable skeleton, who fills each part, and the reference file with the craft. Start here before authoring anything in a form's _data.json.",
@@ -31498,7 +31677,7 @@ function triggerHints(triggers) {
31498
31677
  `A side effect on this step carries \`triggerId: "${triggers.completion}"\`, and \`baker flows add-side-effect\` writes it for you. The trigger belongs to the STEP, not to the side-effect type: one that does not match is valid, ships, and never runs.` + (others.length > 0 ? ` Other moments this step raises: ${others.join(", ")}.` : "")
31499
31678
  ];
31500
31679
  }
31501
- var schemaCommand = defineCommand113({
31680
+ var schemaCommand = defineCommand114({
31502
31681
  meta: {
31503
31682
  name: "schema",
31504
31683
  description: "Show a node or side-effect type's shape. Start here: baker flows schema node customForm \xB7 baker flows schema side-effect googleSpreadsheet \xB7 baker flows schema (lists both)"
@@ -31632,7 +31811,7 @@ function displayName(slug) {
31632
31811
  const name = tree.displayName;
31633
31812
  return typeof name === "string" && name.trim() ? name.trim() : slug;
31634
31813
  }
31635
- var listCommand12 = defineCommand114({
31814
+ var listCommand12 = defineCommand115({
31636
31815
  meta: {
31637
31816
  name: "list",
31638
31817
  description: "List Forms in this workspace with the count of confidential fields still needing setup. Example: baker flows list"
@@ -31653,7 +31832,7 @@ var listCommand12 = defineCommand114({
31653
31832
  });
31654
31833
  }
31655
31834
  });
31656
- var showCommand3 = defineCommand114({
31835
+ var showCommand3 = defineCommand115({
31657
31836
  meta: {
31658
31837
  name: "show",
31659
31838
  description: "Show a Form's confidential fields and their configuration status (never secret values). Example: baker flows show contact"
@@ -31681,7 +31860,7 @@ var showCommand3 = defineCommand114({
31681
31860
  });
31682
31861
  }
31683
31862
  });
31684
- var flowsCommand = defineCommand114({
31863
+ var flowsCommand = defineCommand115({
31685
31864
  meta: {
31686
31865
  name: "flows",
31687
31866
  description: `Read and shape this workspace's Forms (flows).
@@ -31715,10 +31894,10 @@ Full guide: __tooling__/docs/tools/baker/flows.md`
31715
31894
  });
31716
31895
 
31717
31896
  // src/commands/ga4/index.ts
31718
- import { defineCommand as defineCommand121 } from "citty";
31897
+ import { defineCommand as defineCommand122 } from "citty";
31719
31898
 
31720
31899
  // src/commands/ga4/audit.ts
31721
- import { defineCommand as defineCommand115 } from "citty";
31900
+ import { defineCommand as defineCommand116 } from "citty";
31722
31901
 
31723
31902
  // src/commands/ga4/resolve.ts
31724
31903
  async function fetchProperties(useCache = true) {
@@ -31784,7 +31963,7 @@ registerSchema({
31784
31963
  "no-cache": { type: "boolean", description: "Skip cache, hit API directly", required: false }
31785
31964
  }
31786
31965
  });
31787
- var auditCommand2 = defineCommand115({
31966
+ var auditCommand2 = defineCommand116({
31788
31967
  meta: {
31789
31968
  name: "audit",
31790
31969
  description: `Run all GA4 admin health checks. Returns property config with playbook warnings.
@@ -31839,7 +32018,7 @@ Examples:
31839
32018
  });
31840
32019
 
31841
32020
  // src/commands/ga4/config.ts
31842
- import { defineCommand as defineCommand116 } from "citty";
32021
+ import { defineCommand as defineCommand117 } from "citty";
31843
32022
 
31844
32023
  // src/commands/ga4/shared.ts
31845
32024
  import { readFileSync as readFileSync12 } from "fs";
@@ -32035,7 +32214,7 @@ function configHints(config) {
32035
32214
  }
32036
32215
  return hints;
32037
32216
  }
32038
- var configCommand = defineCommand116({
32217
+ var configCommand = defineCommand117({
32039
32218
  meta: {
32040
32219
  name: "config",
32041
32220
  description: `Read how the property is configured to measure \u2014 key events, custom definitions, custom events, retention
@@ -32067,7 +32246,7 @@ Examples:
32067
32246
  });
32068
32247
 
32069
32248
  // src/commands/ga4/draft.ts
32070
- import { defineCommand as defineCommand117 } from "citty";
32249
+ import { defineCommand as defineCommand118 } from "citty";
32071
32250
  registerSchema({
32072
32251
  command: "ga4.draft",
32073
32252
  description: "Review and undo the Google Analytics changes staged on this chat. Use `list` to see everything staged, `show` to inspect one change in full before the chat completes, `amend` to correct one in place, and `remove`/`clear` to drop them. `list` and `show` take --chat <id> to read an earlier chat's changes instead.",
@@ -32076,13 +32255,13 @@ registerSchema({
32076
32255
  chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
32077
32256
  }
32078
32257
  });
32079
- var draftCommand3 = defineCommand117({
32258
+ var draftCommand3 = defineCommand118({
32080
32259
  meta: {
32081
32260
  name: "draft",
32082
32261
  description: "List, show, amend, remove or clear the Google Analytics changes staged on this chat. `list` and `show` take --chat <id> to read an earlier chat's changes instead."
32083
32262
  },
32084
32263
  subCommands: {
32085
- list: defineCommand117({
32264
+ list: defineCommand118({
32086
32265
  meta: { name: "list", description: "Review everything staged on this chat (--json for the raw envelope)" },
32087
32266
  args: {
32088
32267
  json: { type: "boolean", description: "Print the raw JSON envelope", required: false },
@@ -32092,7 +32271,7 @@ var draftCommand3 = defineCommand117({
32092
32271
  await draftList(args.json === true, args.chat);
32093
32272
  }
32094
32273
  }),
32095
- show: defineCommand117({
32274
+ show: defineCommand118({
32096
32275
  meta: {
32097
32276
  name: "show",
32098
32277
  description: "Print the full staged payload for one change, alongside how the property looks today \u2014 the receipt to verify it before the chat completes (never truncated)."
@@ -32109,7 +32288,7 @@ var draftCommand3 = defineCommand117({
32109
32288
  );
32110
32289
  }
32111
32290
  }),
32112
- amend: defineCommand117({
32291
+ amend: defineCommand118({
32113
32292
  meta: {
32114
32293
  name: "amend",
32115
32294
  description: "Update a staged change in place \u2014 merges a JSON patch into its payload (objects deep-merge, null deletes a key, arrays/scalars replace) and re-runs every check. Use this instead of remove + re-create."
@@ -32126,7 +32305,7 @@ var draftCommand3 = defineCommand117({
32126
32305
  });
32127
32306
  }
32128
32307
  }),
32129
- remove: defineCommand117({
32308
+ remove: defineCommand118({
32130
32309
  meta: { name: "remove", description: "Remove one staged change" },
32131
32310
  args: { ref: { type: "positional", description: "Staged ref or target id", required: false } },
32132
32311
  run: async ({ args }) => {
@@ -32135,7 +32314,7 @@ var draftCommand3 = defineCommand117({
32135
32314
  });
32136
32315
  }
32137
32316
  }),
32138
- clear: defineCommand117({
32317
+ clear: defineCommand118({
32139
32318
  meta: { name: "clear", description: "Discard all Google Analytics changes staged on this chat" },
32140
32319
  run: async () => {
32141
32320
  await draftAction2("/api/ga4/draft/clear", {});
@@ -32145,7 +32324,7 @@ var draftCommand3 = defineCommand117({
32145
32324
  });
32146
32325
 
32147
32326
  // src/commands/ga4/properties.ts
32148
- import { defineCommand as defineCommand118 } from "citty";
32327
+ import { defineCommand as defineCommand119 } from "citty";
32149
32328
  registerSchema({
32150
32329
  command: "ga4.properties",
32151
32330
  description: "List the GA4 properties this company connected \u2014 there can be several, and every one of them is yours to query. Returns the property IDs the query and audit commands take. Run this first to find property IDs.",
@@ -32161,7 +32340,7 @@ function propertyHints(properties) {
32161
32340
  resources: properties.map((property) => ({ id: property.externalId, label: property.name }))
32162
32341
  });
32163
32342
  }
32164
- var propertiesCommand = defineCommand118({
32343
+ var propertiesCommand = defineCommand119({
32165
32344
  meta: {
32166
32345
  name: "properties",
32167
32346
  description: `List accessible GA4 properties.
@@ -32211,7 +32390,7 @@ Examples:
32211
32390
  // src/commands/ga4/query.ts
32212
32391
  import { appendFileSync as appendFileSync2, existsSync as existsSync7, readFileSync as readFileSync13, writeFileSync as writeFileSync4 } from "fs";
32213
32392
  import { resolve as resolve2 } from "path";
32214
- import { defineCommand as defineCommand119 } from "citty";
32393
+ import { defineCommand as defineCommand120 } from "citty";
32215
32394
 
32216
32395
  // src/commands/ga4/presets.ts
32217
32396
  var GA4_PRESETS = [
@@ -32346,7 +32525,7 @@ function handleError2(err) {
32346
32525
  });
32347
32526
  process.exit(1);
32348
32527
  }
32349
- var queryCommand2 = defineCommand119({
32528
+ var queryCommand2 = defineCommand120({
32350
32529
  meta: {
32351
32530
  name: "query",
32352
32531
  description: `Run GA4 Data API reports. Preset-first with free-form escape hatch.
@@ -32417,7 +32596,7 @@ Free-form (escape hatch):
32417
32596
  });
32418
32597
 
32419
32598
  // src/commands/ga4/write-commands.ts
32420
- import { defineCommand as defineCommand120 } from "citty";
32599
+ import { defineCommand as defineCommand121 } from "citty";
32421
32600
  var PROPERTY_ARG_DESCRIPTION = "GA4 property id (optional only when one property is connected \u2014 run `baker ga4 properties`)";
32422
32601
  var propertyArg = { type: "string", description: PROPERTY_ARG_DESCRIPTION, required: false };
32423
32602
  function createJsonDescription(noun) {
@@ -32435,7 +32614,7 @@ registerSchema({
32435
32614
  "property-id": { type: "string", description: PROPERTY_ARG_DESCRIPTION, required: false }
32436
32615
  }
32437
32616
  });
32438
- var keyEventCommand = defineCommand120({
32617
+ var keyEventCommand = defineCommand121({
32439
32618
  meta: {
32440
32619
  name: "key-event",
32441
32620
  description: `Stage key-event (conversion) changes
@@ -32448,7 +32627,7 @@ Examples:
32448
32627
  baker ga4 key-event delete 4185`
32449
32628
  },
32450
32629
  subCommands: {
32451
- create: defineCommand120({
32630
+ create: defineCommand121({
32452
32631
  meta: {
32453
32632
  name: "create",
32454
32633
  description: "Stage a new key event. Needs eventName and countingMethod (ONCE_PER_EVENT or ONCE_PER_SESSION); defaultValue sets a monetary value when the event does not send one."
@@ -32469,7 +32648,7 @@ Examples:
32469
32648
  );
32470
32649
  }
32471
32650
  }),
32472
- update: defineCommand120({
32651
+ update: defineCommand121({
32473
32652
  meta: {
32474
32653
  name: "update",
32475
32654
  description: "Stage a change to an existing key event (pass its id). Only countingMethod and defaultValue can change \u2014 Google will not rename a key event."
@@ -32489,7 +32668,7 @@ Examples:
32489
32668
  });
32490
32669
  }
32491
32670
  }),
32492
- delete: defineCommand120({
32671
+ delete: defineCommand121({
32493
32672
  meta: {
32494
32673
  name: "delete",
32495
32674
  description: "Stage removing a key event, so the event stops counting as a conversion. The event itself keeps being collected. Irreversible once the chat completes \u2014 confirm with the user first."
@@ -32537,7 +32716,7 @@ for (const { kind, noun, createHint } of DEFINITIONS) {
32537
32716
  }
32538
32717
  function definitionCommand(definition) {
32539
32718
  const { command, kind, noun, example } = definition;
32540
- return defineCommand120({
32719
+ return defineCommand121({
32541
32720
  meta: {
32542
32721
  name: command,
32543
32722
  description: `Stage ${noun} changes
@@ -32549,7 +32728,7 @@ Examples:
32549
32728
  baker ga4 ${command} archive 12`
32550
32729
  },
32551
32730
  subCommands: {
32552
- create: defineCommand120({
32731
+ create: defineCommand121({
32553
32732
  meta: { name: "create", description: `Stage a new ${noun} (or a JSON array of them, staged together)` },
32554
32733
  args: {
32555
32734
  json: { type: "string", description: createJsonDescription(noun), required: false },
@@ -32567,7 +32746,7 @@ Examples:
32567
32746
  );
32568
32747
  }
32569
32748
  }),
32570
- update: defineCommand120({
32749
+ update: defineCommand121({
32571
32750
  meta: {
32572
32751
  name: "update",
32573
32752
  description: `Stage a change to an existing ${noun} (pass its id). The parameter name and scope cannot change \u2014 archive and recreate for that.`
@@ -32587,7 +32766,7 @@ Examples:
32587
32766
  });
32588
32767
  }
32589
32768
  }),
32590
- archive: defineCommand120({
32769
+ archive: defineCommand121({
32591
32770
  meta: {
32592
32771
  name: "archive",
32593
32772
  description: `Stage archiving a ${noun} (pass its id). It stops collecting and leaves reporting; past data stays. Irreversible once the chat completes \u2014 confirm with the user first.`
@@ -32632,7 +32811,7 @@ var dataStreamArg = {
32632
32811
  function withStream(args) {
32633
32812
  return typeof args["data-stream"] === "string" ? { dataStream: args["data-stream"] } : {};
32634
32813
  }
32635
- var customEventCommand = defineCommand120({
32814
+ var customEventCommand = defineCommand121({
32636
32815
  meta: {
32637
32816
  name: "custom-event",
32638
32817
  description: `Stage custom events \u2014 new events built from events the site already sends
@@ -32643,7 +32822,7 @@ Examples:
32643
32822
  baker ga4 custom-event delete 7`
32644
32823
  },
32645
32824
  subCommands: {
32646
- create: defineCommand120({
32825
+ create: defineCommand121({
32647
32826
  meta: {
32648
32827
  name: "create",
32649
32828
  description: "Stage a new custom event. Conditions match the source event: use field `event_name` to match the event itself, or any parameter name to match its value."
@@ -32666,7 +32845,7 @@ Examples:
32666
32845
  );
32667
32846
  }
32668
32847
  }),
32669
- update: defineCommand120({
32848
+ update: defineCommand121({
32670
32849
  meta: { name: "update", description: "Stage a change to an existing custom event (pass its id)" },
32671
32850
  args: {
32672
32851
  id: { type: "positional", description: "Custom event rule id", required: false },
@@ -32685,7 +32864,7 @@ Examples:
32685
32864
  });
32686
32865
  }
32687
32866
  }),
32688
- delete: defineCommand120({
32867
+ delete: defineCommand121({
32689
32868
  meta: {
32690
32869
  name: "delete",
32691
32870
  description: "Stage removing a custom event (pass its id). The event stops being created from then on; data already collected under it stays. Confirm with the user first."
@@ -32740,7 +32919,7 @@ function booleanArg(input, flag) {
32740
32919
  if (input === "false") return false;
32741
32920
  return failValidation3(`--${flag} must be true or false`);
32742
32921
  }
32743
- var dataRetentionCommand = defineCommand120({
32922
+ var dataRetentionCommand = defineCommand121({
32744
32923
  meta: {
32745
32924
  name: "data-retention",
32746
32925
  description: `Stage a change to how long Google Analytics keeps data
@@ -32750,7 +32929,7 @@ Examples:
32750
32929
  baker ga4 data-retention set --event-data 14 --user-data 14 --reset-on-activity true`
32751
32930
  },
32752
32931
  subCommands: {
32753
- set: defineCommand120({
32932
+ set: defineCommand121({
32754
32933
  meta: { name: "set", description: "Stage the retention window (months)" },
32755
32934
  args: {
32756
32935
  "event-data": { type: "string", description: "2, 14, 26, 38 or 50", required: false },
@@ -32786,7 +32965,7 @@ registerSchema({
32786
32965
  "property-id": { type: "string", description: PROPERTY_ARG_DESCRIPTION, required: false }
32787
32966
  }
32788
32967
  });
32789
- var audienceCommand = defineCommand120({
32968
+ var audienceCommand = defineCommand121({
32790
32969
  meta: {
32791
32970
  name: "audience",
32792
32971
  description: `Stage audience changes (saved groups of users, for retargeting and analysis)
@@ -32818,7 +32997,7 @@ Examples:
32818
32997
  baker ga4 audience archive 8813`
32819
32998
  },
32820
32999
  subCommands: {
32821
- create: defineCommand120({
33000
+ create: defineCommand121({
32822
33001
  meta: { name: "create", description: createJsonDescription("audience") },
32823
33002
  args: {
32824
33003
  json: { type: "string", description: createJsonDescription("audience"), required: false },
@@ -32836,7 +33015,7 @@ Examples:
32836
33015
  );
32837
33016
  }
32838
33017
  }),
32839
- update: defineCommand120({
33018
+ update: defineCommand121({
32840
33019
  meta: {
32841
33020
  name: "update",
32842
33021
  description: "Stage a new name or description (pass the audience id). Who is in it cannot be changed."
@@ -32857,7 +33036,7 @@ Examples:
32857
33036
  });
32858
33037
  }
32859
33038
  }),
32860
- archive: defineCommand120({
33039
+ archive: defineCommand121({
32861
33040
  meta: {
32862
33041
  name: "archive",
32863
33042
  description: "Stage retiring an audience. Cannot be undone \u2014 the users it gathered do not come back."
@@ -32886,7 +33065,7 @@ registerSchema({
32886
33065
  "property-id": { type: "string", description: PROPERTY_ARG_DESCRIPTION, required: false }
32887
33066
  }
32888
33067
  });
32889
- var propertyCommand = defineCommand120({
33068
+ var propertyCommand = defineCommand121({
32890
33069
  meta: {
32891
33070
  name: "property",
32892
33071
  description: `Stage a change to the property's own settings
@@ -32896,7 +33075,7 @@ Examples:
32896
33075
  baker ga4 property set --name "Acme \u2014 Web" --industry REAL_ESTATE`
32897
33076
  },
32898
33077
  subCommands: {
32899
- set: defineCommand120({
33078
+ set: defineCommand121({
32900
33079
  meta: { name: "set", description: "Stage the property name and/or industry category" },
32901
33080
  args: {
32902
33081
  name: { type: "string", description: "New property display name", required: false },
@@ -32936,7 +33115,7 @@ registerSchema({
32936
33115
  "property-id": { type: "string", description: PROPERTY_ARG_DESCRIPTION, required: false }
32937
33116
  }
32938
33117
  });
32939
- var adsLinkCommand = defineCommand120({
33118
+ var adsLinkCommand = defineCommand121({
32940
33119
  meta: {
32941
33120
  name: "ads-link",
32942
33121
  description: `Stage linking this property to a Google Ads account
@@ -32951,7 +33130,7 @@ Examples:
32951
33130
  baker ga4 ads-link delete L1234`
32952
33131
  },
32953
33132
  subCommands: {
32954
- create: defineCommand120({
33133
+ create: defineCommand121({
32955
33134
  meta: { name: "create", description: "Stage linking the property to a Google Ads account" },
32956
33135
  args: {
32957
33136
  "customer-id": { type: "string", description: "Google Ads customer id (123-456-7890)", required: false },
@@ -32970,7 +33149,7 @@ Examples:
32970
33149
  await stageOp3({ kind: "ga4.googleAdsLink.create", payload, ...withProperty(args) });
32971
33150
  }
32972
33151
  }),
32973
- update: defineCommand120({
33152
+ update: defineCommand121({
32974
33153
  meta: {
32975
33154
  name: "update",
32976
33155
  description: "Stage the ads-personalisation setting on an existing link (pass its id)"
@@ -32992,7 +33171,7 @@ Examples:
32992
33171
  });
32993
33172
  }
32994
33173
  }),
32995
- delete: defineCommand120({
33174
+ delete: defineCommand121({
32996
33175
  meta: {
32997
33176
  name: "delete",
32998
33177
  description: "Stage unlinking. Stops conversion imports and strands every audience on this property."
@@ -33043,7 +33222,7 @@ var MEASUREMENT_FLAGS = {
33043
33222
  "page-changes": "pageChangesEnabled",
33044
33223
  "form-interactions": "formInteractionsEnabled"
33045
33224
  };
33046
- var enhancedMeasurementCommand = defineCommand120({
33225
+ var enhancedMeasurementCommand = defineCommand121({
33047
33226
  meta: {
33048
33227
  name: "enhanced-measurement",
33049
33228
  description: `Stage the automatic events GA4 collects on a website stream
@@ -33057,7 +33236,7 @@ Examples:
33057
33236
  baker ga4 enhanced-measurement set --video false`
33058
33237
  },
33059
33238
  subCommands: {
33060
- set: defineCommand120({
33239
+ set: defineCommand121({
33061
33240
  meta: { name: "set", description: "Stage which automatic events the website stream collects" },
33062
33241
  args: {
33063
33242
  scrolls: { type: "string", description: "true|false", required: false },
@@ -33100,7 +33279,7 @@ Examples:
33100
33279
  });
33101
33280
 
33102
33281
  // src/commands/ga4/index.ts
33103
- var ga4Command = defineCommand121({
33282
+ var ga4Command = defineCommand122({
33104
33283
  meta: {
33105
33284
  name: "ga4",
33106
33285
  description: `Google Analytics 4. Report on a property, audit its config, and change what it measures.
@@ -33149,12 +33328,12 @@ Full guide: __tooling__/docs/tools/baker/ga4.md`
33149
33328
  });
33150
33329
 
33151
33330
  // src/commands/gsc/index.ts
33152
- import { defineCommand as defineCommand125 } from "citty";
33331
+ import { defineCommand as defineCommand126 } from "citty";
33153
33332
 
33154
33333
  // src/commands/gsc/query.ts
33155
33334
  import { appendFileSync as appendFileSync3, existsSync as existsSync8, readFileSync as readFileSync14, writeFileSync as writeFileSync5 } from "fs";
33156
33335
  import { resolve as resolve3 } from "path";
33157
- import { defineCommand as defineCommand122 } from "citty";
33336
+ import { defineCommand as defineCommand123 } from "citty";
33158
33337
 
33159
33338
  // src/commands/gsc/presets.ts
33160
33339
  var GSC_PRESETS = [
@@ -33348,7 +33527,7 @@ function handleError3(err) {
33348
33527
  });
33349
33528
  process.exit(1);
33350
33529
  }
33351
- var queryCommand3 = defineCommand122({
33530
+ var queryCommand3 = defineCommand123({
33352
33531
  meta: {
33353
33532
  name: "query",
33354
33533
  description: `Run GSC Search Analytics queries. Preset-first with free-form escape hatch.
@@ -33426,7 +33605,7 @@ Free-form (escape hatch):
33426
33605
  });
33427
33606
 
33428
33607
  // src/commands/gsc/sitemaps.ts
33429
- import { defineCommand as defineCommand123 } from "citty";
33608
+ import { defineCommand as defineCommand124 } from "citty";
33430
33609
  registerSchema({
33431
33610
  command: "gsc.sitemaps",
33432
33611
  description: "List sitemaps for a Search Console site. Check sitemap health and errors.",
@@ -33435,7 +33614,7 @@ registerSchema({
33435
33614
  "no-cache": { type: "boolean", description: "Skip cache, hit API directly", required: false }
33436
33615
  }
33437
33616
  });
33438
- var sitemapsCommand = defineCommand123({
33617
+ var sitemapsCommand = defineCommand124({
33439
33618
  meta: {
33440
33619
  name: "sitemaps",
33441
33620
  description: `List sitemaps for a site. Check health and errors.
@@ -33488,7 +33667,7 @@ Examples:
33488
33667
  });
33489
33668
 
33490
33669
  // src/commands/gsc/sites.ts
33491
- import { defineCommand as defineCommand124 } from "citty";
33670
+ import { defineCommand as defineCommand125 } from "citty";
33492
33671
  registerSchema({
33493
33672
  command: "gsc.sites",
33494
33673
  description: "List the Search Console sites this company connected \u2014 there can be several, and every one of them is yours to query. Returns the site URLs the query and sitemaps commands take.",
@@ -33504,7 +33683,7 @@ function siteHints(sites) {
33504
33683
  resources: sites.map((site) => ({ id: site.siteUrl, label: site.permissionLevel }))
33505
33684
  });
33506
33685
  }
33507
- var sitesCommand = defineCommand124({
33686
+ var sitesCommand = defineCommand125({
33508
33687
  meta: {
33509
33688
  name: "sites",
33510
33689
  description: `List verified Search Console sites.
@@ -33552,7 +33731,7 @@ Examples:
33552
33731
  });
33553
33732
 
33554
33733
  // src/commands/gsc/index.ts
33555
- var gscCommand = defineCommand125({
33734
+ var gscCommand = defineCommand126({
33556
33735
  meta: {
33557
33736
  name: "gsc",
33558
33737
  description: `Google Search Console commands. PPC-SEO arbitrage, brand halo analysis, negative keyword discovery.
@@ -33576,7 +33755,7 @@ Full guide: __tooling__/docs/tools/baker/gsc.md`
33576
33755
  });
33577
33756
 
33578
33757
  // src/commands/history/index.ts
33579
- import { defineCommand as defineCommand126 } from "citty";
33758
+ import { defineCommand as defineCommand127 } from "citty";
33580
33759
  registerSchema({
33581
33760
  command: "history.list",
33582
33761
  description: "Start here: unified account history (audit log) \u2014 everything that changed on this account, newest first: publishes, chat lifecycle, backlog actions, team changes, setup links, tags, schedules, ad-platform writes, followed advertisers, media, creatives, reports, domains, and integrations. Use it to see what happened recently before planning work. Compact by default; add --full for raw metadata per entry.",
@@ -33631,7 +33810,7 @@ function parseBoundedInt2(raw, name, min, max) {
33631
33810
  }
33632
33811
  return value;
33633
33812
  }
33634
- var listCommand13 = defineCommand126({
33813
+ var listCommand13 = defineCommand127({
33635
33814
  meta: {
33636
33815
  name: "list",
33637
33816
  description: "List recent account changes (unified audit log), newest first."
@@ -33677,7 +33856,7 @@ var listCommand13 = defineCommand126({
33677
33856
  }
33678
33857
  }
33679
33858
  });
33680
- var historyCommand = defineCommand126({
33859
+ var historyCommand = defineCommand127({
33681
33860
  meta: {
33682
33861
  name: "history",
33683
33862
  description: `Unified account history (audit log): what changed, who did it, and when.
@@ -33687,7 +33866,7 @@ Full guide: __tooling__/docs/tools/baker/history.md`
33687
33866
  });
33688
33867
 
33689
33868
  // src/commands/hubspot/index.ts
33690
- import { defineCommand as defineCommand127 } from "citty";
33869
+ import { defineCommand as defineCommand128 } from "citty";
33691
33870
  var EMBED_TYPES = ["legacy", "v4", "unknown"];
33692
33871
  function failNotConnected(err) {
33693
33872
  if (err instanceof ApiError && err.code === "FORBIDDEN" && err.message.includes(HUBSPOT_MISSING_GRANT_MARKER)) {
@@ -33841,7 +34020,7 @@ registerSchema({
33841
34020
  }
33842
34021
  }
33843
34022
  });
33844
- var formsListCommand = defineCommand127({
34023
+ var formsListCommand = defineCommand128({
33845
34024
  meta: {
33846
34025
  name: "list",
33847
34026
  description: "List HubSpot forms with embed type and post-submit action. Example: baker hubspot forms list --redirecting-only"
@@ -33886,7 +34065,7 @@ var formsListCommand = defineCommand127({
33886
34065
  }
33887
34066
  }
33888
34067
  });
33889
- var formsViewCommand = defineCommand127({
34068
+ var formsViewCommand = defineCommand128({
33890
34069
  meta: {
33891
34070
  name: "view",
33892
34071
  description: "Show one HubSpot form's fields and configuration. Example: baker hubspot forms view 1a2b3c"
@@ -33938,7 +34117,7 @@ var formsViewCommand = defineCommand127({
33938
34117
  }
33939
34118
  }
33940
34119
  });
33941
- var meetingsListCommand = defineCommand127({
34120
+ var meetingsListCommand = defineCommand128({
33942
34121
  meta: {
33943
34122
  name: "list",
33944
34123
  description: "List HubSpot meeting links (calendars). Example: baker hubspot meetings list"
@@ -33980,7 +34159,7 @@ var meetingsListCommand = defineCommand127({
33980
34159
  }
33981
34160
  }
33982
34161
  });
33983
- var meetingsViewCommand = defineCommand127({
34162
+ var meetingsViewCommand = defineCommand128({
33984
34163
  meta: {
33985
34164
  name: "view",
33986
34165
  description: "Show one HubSpot meeting link's booking fields. Example: baker hubspot meetings view discovery-call"
@@ -34024,7 +34203,7 @@ var meetingsViewCommand = defineCommand127({
34024
34203
  }
34025
34204
  }
34026
34205
  });
34027
- var formsSubmissionsCommand = defineCommand127({
34206
+ var formsSubmissionsCommand = defineCommand128({
34028
34207
  meta: {
34029
34208
  name: "submissions",
34030
34209
  description: "How many leads a form received, and when. Example: baker hubspot forms submissions <formId> --days 30"
@@ -34073,7 +34252,7 @@ var formsSubmissionsCommand = defineCommand127({
34073
34252
  }
34074
34253
  }
34075
34254
  });
34076
- var workflowsListCommand = defineCommand127({
34255
+ var workflowsListCommand = defineCommand128({
34077
34256
  meta: {
34078
34257
  name: "list",
34079
34258
  description: "List HubSpot workflows. Example: baker hubspot workflows list --enabled-only"
@@ -34138,7 +34317,7 @@ function workflowViewHints(workflow) {
34138
34317
  }
34139
34318
  return hints;
34140
34319
  }
34141
- var workflowsViewCommand = defineCommand127({
34320
+ var workflowsViewCommand = defineCommand128({
34142
34321
  meta: {
34143
34322
  name: "view",
34144
34323
  description: "Read one workflow's real configuration \u2014 enrolment, branches in order, and what each step writes. Example: baker hubspot workflows view 121183594 --full"
@@ -34165,7 +34344,7 @@ var workflowsViewCommand = defineCommand127({
34165
34344
  }
34166
34345
  }
34167
34346
  });
34168
- var pipelinesListCommand = defineCommand127({
34347
+ var pipelinesListCommand = defineCommand128({
34169
34348
  meta: {
34170
34349
  name: "list",
34171
34350
  description: "List HubSpot deal pipelines and their stages. Example: baker hubspot pipelines list"
@@ -34182,7 +34361,7 @@ var pipelinesListCommand = defineCommand127({
34182
34361
  }
34183
34362
  }
34184
34363
  });
34185
- var contactsSummaryCommand = defineCommand127({
34364
+ var contactsSummaryCommand = defineCommand128({
34186
34365
  meta: {
34187
34366
  name: "summary",
34188
34367
  description: "Whether recent leads are being worked, as counts. Example: baker hubspot contacts summary --days 30"
@@ -34252,7 +34431,7 @@ function contactLookupHints(data) {
34252
34431
  }
34253
34432
  return hints;
34254
34433
  }
34255
- var contactsLookupCommand = defineCommand127({
34434
+ var contactsLookupCommand = defineCommand128({
34256
34435
  meta: {
34257
34436
  name: "lookup",
34258
34437
  description: "Find one contact by email and see whether it was worked. Example: baker hubspot contacts lookup a@b.com"
@@ -34276,27 +34455,27 @@ var contactsLookupCommand = defineCommand127({
34276
34455
  }
34277
34456
  }
34278
34457
  });
34279
- var contactsCommand = defineCommand127({
34458
+ var contactsCommand = defineCommand128({
34280
34459
  meta: { name: "contacts", description: "Contacts on the connected HubSpot account." },
34281
34460
  subCommands: { summary: contactsSummaryCommand, lookup: contactsLookupCommand }
34282
34461
  });
34283
- var formsCommand = defineCommand127({
34462
+ var formsCommand = defineCommand128({
34284
34463
  meta: { name: "forms", description: "HubSpot forms on the connected account." },
34285
34464
  subCommands: { list: formsListCommand, view: formsViewCommand, submissions: formsSubmissionsCommand }
34286
34465
  });
34287
- var workflowsCommand = defineCommand127({
34466
+ var workflowsCommand = defineCommand128({
34288
34467
  meta: { name: "workflows", description: "HubSpot workflows on the connected account." },
34289
34468
  subCommands: { list: workflowsListCommand, view: workflowsViewCommand }
34290
34469
  });
34291
- var pipelinesCommand = defineCommand127({
34470
+ var pipelinesCommand = defineCommand128({
34292
34471
  meta: { name: "pipelines", description: "HubSpot deal pipelines on the connected account." },
34293
34472
  subCommands: { list: pipelinesListCommand }
34294
34473
  });
34295
- var meetingsCommand = defineCommand127({
34474
+ var meetingsCommand = defineCommand128({
34296
34475
  meta: { name: "meetings", description: "HubSpot meeting links (calendars) on the connected account." },
34297
34476
  subCommands: { list: meetingsListCommand, view: meetingsViewCommand }
34298
34477
  });
34299
- var hubspotCommand = defineCommand127({
34478
+ var hubspotCommand = defineCommand128({
34300
34479
  meta: {
34301
34480
  name: "hubspot",
34302
34481
  description: `Read the connected HubSpot account \u2014 forms, the leads they received, workflows, deal pipelines and
@@ -34334,10 +34513,10 @@ Full guide: __tooling__/docs/tools/baker/hubspot.md`
34334
34513
  });
34335
34514
 
34336
34515
  // src/commands/images/index.ts
34337
- import { defineCommand as defineCommand153 } from "citty";
34516
+ import { defineCommand as defineCommand154 } from "citty";
34338
34517
 
34339
34518
  // src/commands/images/crop.ts
34340
- import { defineCommand as defineCommand128 } from "citty";
34519
+ import { defineCommand as defineCommand129 } from "citty";
34341
34520
 
34342
34521
  // src/lib/image/crop-sprite.ts
34343
34522
  import sharp from "sharp";
@@ -34459,7 +34638,7 @@ function emitError2(err) {
34459
34638
  }
34460
34639
  process.exit(1);
34461
34640
  }
34462
- var cropCommand = defineCommand128({
34641
+ var cropCommand = defineCommand129({
34463
34642
  meta: {
34464
34643
  name: "crop",
34465
34644
  description: "Crop a rectangular region from an image.\n\nExample: baker images crop sprite.png --x 0 --y 0 --width 64 --height 64 --output icon.png"
@@ -34495,7 +34674,7 @@ var cropCommand = defineCommand128({
34495
34674
  });
34496
34675
 
34497
34676
  // src/commands/images/delete.ts
34498
- import { defineCommand as defineCommand129 } from "citty";
34677
+ import { defineCommand as defineCommand130 } from "citty";
34499
34678
  registerSchema({
34500
34679
  command: "images.delete",
34501
34680
  description: "Delete an image by ID",
@@ -34509,7 +34688,7 @@ registerSchema({
34509
34688
  }
34510
34689
  }
34511
34690
  });
34512
- var deleteCommand2 = defineCommand129({
34691
+ var deleteCommand2 = defineCommand130({
34513
34692
  meta: {
34514
34693
  name: "delete",
34515
34694
  description: "Delete an image by ID. Use --dry-run to preview. Example: baker images delete j571abc123 --dry-run"
@@ -34550,7 +34729,7 @@ var deleteCommand2 = defineCommand129({
34550
34729
  });
34551
34730
 
34552
34731
  // src/commands/images/dimensions.ts
34553
- import { defineCommand as defineCommand130 } from "citty";
34732
+ import { defineCommand as defineCommand131 } from "citty";
34554
34733
 
34555
34734
  // src/lib/image/dimensions.ts
34556
34735
  import { imageSize } from "image-size";
@@ -34579,7 +34758,7 @@ registerSchema({
34579
34758
  }
34580
34759
  }
34581
34760
  });
34582
- var dimensionsCommand = defineCommand130({
34761
+ var dimensionsCommand = defineCommand131({
34583
34762
  meta: {
34584
34763
  name: "dimensions",
34585
34764
  description: "Read image dimensions without decoding the full file.\n\nExample: baker images dimensions ./logo.png\nExample: baker images dimensions https://acme.com/hero.png"
@@ -34635,7 +34814,7 @@ var dimensionsCommand = defineCommand130({
34635
34814
  });
34636
34815
 
34637
34816
  // src/commands/images/download.ts
34638
- import { defineCommand as defineCommand131 } from "citty";
34817
+ import { defineCommand as defineCommand132 } from "citty";
34639
34818
 
34640
34819
  // src/commands/images/downloadPaths.ts
34641
34820
  import { basename as basename2, extname as extname3, join as join6 } from "path";
@@ -34860,7 +35039,7 @@ function emitError3(err) {
34860
35039
  writeJson({ ok: false, error: { code: "INTERNAL_ERROR", message: "Unexpected error" } });
34861
35040
  process.exit(1);
34862
35041
  }
34863
- var downloadCommand = defineCommand131({
35042
+ var downloadCommand = defineCommand132({
34864
35043
  meta: {
34865
35044
  name: "download",
34866
35045
  description: "Download image URLs and/or library images to local files \u2014 the missing first half of `source \u2192 download \u2192 normalize \u2192 place`. Never use `curl` for this.\n\nExamples:\n baker images download https://media.withbaker.com/\u2026/logo.webp\n baker images download j57abc123 j57def456 --out src/pages/pricing/_images/\n baker images download https://\u2026/hero.png --out ./hero.png"
@@ -34893,7 +35072,7 @@ var downloadCommand = defineCommand131({
34893
35072
  });
34894
35073
 
34895
35074
  // src/commands/images/extract.ts
34896
- import { defineCommand as defineCommand132 } from "citty";
35075
+ import { defineCommand as defineCommand133 } from "citty";
34897
35076
 
34898
35077
  // src/commands/images/autoIngest.ts
34899
35078
  var AUTO_INGEST_MAX = {
@@ -34940,7 +35119,7 @@ registerSchema({
34940
35119
  }
34941
35120
  }
34942
35121
  });
34943
- var extractCommand = defineCommand132({
35122
+ var extractCommand = defineCommand133({
34944
35123
  meta: {
34945
35124
  name: "extract",
34946
35125
  description: "Pull every image from a single URL via Firecrawl. ~$0.001/scrape. Cap auto-ingest at 20.\n\nExample: baker images extract https://stripe.com --auto-ingest 5"
@@ -34995,7 +35174,7 @@ var extractCommand = defineCommand132({
34995
35174
  });
34996
35175
 
34997
35176
  // src/commands/images/find.ts
34998
- import { defineCommand as defineCommand133 } from "citty";
35177
+ import { defineCommand as defineCommand134 } from "citty";
34999
35178
 
35000
35179
  // src/commands/images/providerHits.ts
35001
35180
  function asRecord3(value) {
@@ -35133,7 +35312,7 @@ registerSchema({
35133
35312
  full: { type: "boolean", description: "Include full metadata", required: false, default: false }
35134
35313
  }
35135
35314
  });
35136
- var findCommand = defineCommand133({
35315
+ var findCommand = defineCommand134({
35137
35316
  meta: {
35138
35317
  name: "find",
35139
35318
  description: "Library-first fanout image search. Opt in to providers with --sources. `--fallback` short-circuits to externals only when library is thin. With --auto-ingest, ingested external hits return Baker-owned URLs.\n\nExample: baker images find 'office' --sources library,magnific --limit 20"
@@ -35206,7 +35385,7 @@ var findCommand = defineCommand133({
35206
35385
  });
35207
35386
 
35208
35387
  // src/commands/images/get.ts
35209
- import { defineCommand as defineCommand134 } from "citty";
35388
+ import { defineCommand as defineCommand135 } from "citty";
35210
35389
  registerSchema({
35211
35390
  command: "images.get",
35212
35391
  description: "Get a single image by ID",
@@ -35214,7 +35393,7 @@ registerSchema({
35214
35393
  id: { type: "string", description: "Image ID", required: true }
35215
35394
  }
35216
35395
  });
35217
- var getCommand3 = defineCommand134({
35396
+ var getCommand3 = defineCommand135({
35218
35397
  meta: { name: "get", description: "Get a single image by ID. Example: baker images get j571abc123" },
35219
35398
  args: {
35220
35399
  id: { type: "positional", description: "Image ID", required: false },
@@ -35250,7 +35429,7 @@ var getCommand3 = defineCommand134({
35250
35429
  });
35251
35430
 
35252
35431
  // src/commands/images/gif.ts
35253
- import { defineCommand as defineCommand135 } from "citty";
35432
+ import { defineCommand as defineCommand136 } from "citty";
35254
35433
  registerSchema({
35255
35434
  command: "images.gif",
35256
35435
  description: "Search Giphy for GIFs / reaction memes (paid social creative).",
@@ -35282,7 +35461,7 @@ registerSchema({
35282
35461
  }
35283
35462
  }
35284
35463
  });
35285
- var gifCommand = defineCommand135({
35464
+ var gifCommand = defineCommand136({
35286
35465
  meta: {
35287
35466
  name: "gif",
35288
35467
  description: "Search Giphy for GIFs / reaction memes \u2014 built for paid-social creative (Meta, TikTok, LinkedIn, X). Free API. Each hit carries WebP + GIF + MP4 URLs in providerMeta so you can pick the right format per platform.\n\nExample: baker images gif 'this is fine' --limit 10\nExample: baker images gif 'office reaction' --rating pg --auto-ingest 2\nExample: baker images gif --trending --limit 25"
@@ -35329,7 +35508,7 @@ var gifCommand = defineCommand135({
35329
35508
  });
35330
35509
 
35331
35510
  // src/commands/images/google.ts
35332
- import { defineCommand as defineCommand136 } from "citty";
35511
+ import { defineCommand as defineCommand137 } from "citty";
35333
35512
  var GOOGLE_ERROR_FIX = {
35334
35513
  action: "use_different_resource",
35335
35514
  explanation: "Generate the asset instead of retrying Google. Google is the last-resort image provider. Run `baker studio generate` to make the asset. Never sleep-and-retry this command \u2014 the CLI already backs off on rate limits. If no image can be sourced, continue the rest of the task with a placeholder rather than aborting it."
@@ -35369,7 +35548,7 @@ registerSchema({
35369
35548
  }
35370
35549
  }
35371
35550
  });
35372
- var googleCommand2 = defineCommand136({
35551
+ var googleCommand2 = defineCommand137({
35373
35552
  meta: {
35374
35553
  name: "google",
35375
35554
  description: "Google Images via the official Custom Search JSON API ($0.005/query, free 100/day). \u26A0 Source unverified \u2014 watermarks, low-res, mislabeled results are common. Use as last resort. With --auto-ingest, ingested hits return Baker-owned URLs.\n\nExample: baker images google 'industrial workshop' --type photo --size large --limit 20"
@@ -35442,7 +35621,7 @@ var googleCommand2 = defineCommand136({
35442
35621
  });
35443
35622
 
35444
35623
  // src/commands/images/group.ts
35445
- import { defineCommand as defineCommand137 } from "citty";
35624
+ import { defineCommand as defineCommand138 } from "citty";
35446
35625
 
35447
35626
  // src/commands/mediaGroup.ts
35448
35627
  async function runMediaGroupLookup(input) {
@@ -35495,7 +35674,7 @@ registerSchema({
35495
35674
  "group-key": { type: "string", description: "The set key directly, when you already have it", required: false }
35496
35675
  }
35497
35676
  });
35498
- var groupCommand = defineCommand137({
35677
+ var groupCommand = defineCommand138({
35499
35678
  meta: {
35500
35679
  name: "group",
35501
35680
  description: "List every asset that arrived in the same set \u2014 the slides of one Instagram carousel, the images off one scraped page. Start here whenever a hit looks like part of a sequence: carousel slides are authored to be read in order and usually only make sense together. Takes an image or a video id, since one carousel can contain both. Example: baker images group <imageId>"
@@ -35515,7 +35694,7 @@ var groupCommand = defineCommand137({
35515
35694
  });
35516
35695
 
35517
35696
  // src/commands/images/icon.ts
35518
- import { defineCommand as defineCommand138 } from "citty";
35697
+ import { defineCommand as defineCommand139 } from "citty";
35519
35698
 
35520
35699
  // src/commands/images/brandVerification.ts
35521
35700
  function brandToken(domain) {
@@ -35612,7 +35791,7 @@ registerSchema({
35612
35791
  full: { type: "boolean", description: "Include full metadata", required: false, default: false }
35613
35792
  }
35614
35793
  });
35615
- var iconCommand = defineCommand138({
35794
+ var iconCommand = defineCommand139({
35616
35795
  meta: {
35617
35796
  name: "icon",
35618
35797
  description: "Icon via Iconify (simple-icons, logos, lucide, devicon, heroicons, tabler, phosphor, material-symbols, \u2026). Free CDN, no API key.\n\nExample: baker images icon react --set devicon\nExample: baker images icon lucide:check --color '#0a0a0a'"
@@ -35682,7 +35861,7 @@ var iconCommand = defineCommand138({
35682
35861
  });
35683
35862
 
35684
35863
  // src/commands/images/ingest.ts
35685
- import { defineCommand as defineCommand139 } from "citty";
35864
+ import { defineCommand as defineCommand140 } from "citty";
35686
35865
  var SOURCE_VALUES = imageSourceSchema.options.join(" | ");
35687
35866
  registerSchema({
35688
35867
  command: "images.ingest",
@@ -35697,7 +35876,7 @@ registerSchema({
35697
35876
  fields: { type: "string", description: "Comma-separated field names to include", required: false }
35698
35877
  }
35699
35878
  });
35700
- var ingestCommand = defineCommand139({
35879
+ var ingestCommand = defineCommand140({
35701
35880
  meta: {
35702
35881
  name: "ingest",
35703
35882
  description: "Download a remote URL and store it in the library. Hash-deduped on bytes + externalId.\n\nExample: baker images ingest https://img.freepik.com/free-photo/xyz.jpg --source magnific --external-id 12345"
@@ -35766,7 +35945,7 @@ var ingestCommand = defineCommand139({
35766
35945
  });
35767
35946
 
35768
35947
  // src/commands/images/layerize.ts
35769
- import { defineCommand as defineCommand140 } from "citty";
35948
+ import { defineCommand as defineCommand141 } from "citty";
35770
35949
  registerSchema({
35771
35950
  command: "images.layerize",
35772
35951
  description: "Split a library image into editable layers: transparent PNG cutouts for each element, plus any headline recovered as EDITABLE TEXT with its font, size, colour and position. Waits for completion by default. Costs credits.",
@@ -35830,7 +36009,7 @@ async function pollUntilSettled(imageId, maxWait) {
35830
36009
  }
35831
36010
  return null;
35832
36011
  }
35833
- var layerizeCommand = defineCommand140({
36012
+ var layerizeCommand = defineCommand141({
35834
36013
  meta: {
35835
36014
  name: "layerize",
35836
36015
  description: "Split a library image into editable layers \u2014 transparent cutouts per element, plus any baked-in headline recovered as editable text with its typography.\n\nStart here: baker images layerize j571abc123def\nExample: baker images layerize j571abc123def --full\nExample: baker images layerize j571abc123def --instructions 'keep the product and its shadow together'"
@@ -35899,7 +36078,7 @@ registerSchema({
35899
36078
  full: { type: "boolean", description: "Include geometry and typography for every layer", required: false }
35900
36079
  }
35901
36080
  });
35902
- var layersCommand = defineCommand140({
36081
+ var layersCommand = defineCommand141({
35903
36082
  meta: {
35904
36083
  name: "layers",
35905
36084
  description: "Read the layers of an image that has already been split. Free \u2014 no provider call.\n\nStart here: baker images layers j571abc123def\nExample: baker images layers j571abc123def --full"
@@ -35939,7 +36118,7 @@ var layersCommand = defineCommand140({
35939
36118
  });
35940
36119
 
35941
36120
  // src/commands/images/library.ts
35942
- import { defineCommand as defineCommand141 } from "citty";
36121
+ import { defineCommand as defineCommand142 } from "citty";
35943
36122
  registerSchema({
35944
36123
  command: "images.library",
35945
36124
  description: "Search the company image library. Returns only ready images.",
@@ -35965,7 +36144,7 @@ registerSchema({
35965
36144
  }
35966
36145
  }
35967
36146
  });
35968
- var libraryCommand = defineCommand141({
36147
+ var libraryCommand = defineCommand142({
35969
36148
  meta: {
35970
36149
  name: "library",
35971
36150
  description: "Search the company image library (hybrid BM25 + vector + Cohere rerank). Use this BEFORE any external provider.\n\nExample: baker images library 'hero banner' --aspect-ratio 16:9 --source magnific"
@@ -36028,7 +36207,7 @@ var libraryCommand = defineCommand141({
36028
36207
  });
36029
36208
 
36030
36209
  // src/commands/images/logo.ts
36031
- import { defineCommand as defineCommand142 } from "citty";
36210
+ import { defineCommand as defineCommand143 } from "citty";
36032
36211
  registerSchema({
36033
36212
  command: "images.logo",
36034
36213
  description: "Brand logo lookup via Brandfetch. Auto-ingests by default. Returns `brandMatch` \u2014 Brandfetch's own verdict on whose brand the domain is (confirmed | mismatch | unverified). Branch on it: `mismatch` means the mark is another company's, so do not place it. `confirmed` verifies the record, not the artwork \u2014 read the ingested row back to check the mark itself.",
@@ -36056,7 +36235,7 @@ registerSchema({
36056
36235
  full: { type: "boolean", description: "Include full metadata", required: false, default: false }
36057
36236
  }
36058
36237
  });
36059
- var logoCommand = defineCommand142({
36238
+ var logoCommand = defineCommand143({
36060
36239
  meta: {
36061
36240
  name: "logo",
36062
36241
  description: "Brand logo via Brandfetch. Returns up to 5 variants (icon, light/dark logo, light/dark symbol) plus `brandMatch`. Auto-ingests the first variant.\n\nStart here: check `brandMatch.verdict`.\n mismatch \u2192 the mark belongs to `brandMatch.name`, a different company. Do not place it.\n unverified \u2192 nothing confirmed whose logo this is. Treat as unchecked.\n confirmed \u2192 Brandfetch has this brand's record. That verifies the record, NOT the artwork \u2014 a confirmed domain has served another company's logo before.\n\n\u26A0 Whatever the verdict, read the ingested row back with `baker images get <imageId>` and check `textInImage`/`subject` before placing it. That is the only check that looks at the mark.\n\nExample: baker images logo stripe.com --variant logo"
@@ -36129,7 +36308,7 @@ var logoCommand = defineCommand142({
36129
36308
  });
36130
36309
 
36131
36310
  // src/commands/images/normalize.ts
36132
- import { defineCommand as defineCommand143 } from "citty";
36311
+ import { defineCommand as defineCommand144 } from "citty";
36133
36312
 
36134
36313
  // src/lib/image/color-changer.ts
36135
36314
  import quantize from "quantize";
@@ -36861,7 +37040,7 @@ function coerceRawArgs(args) {
36861
37040
  "dry-run": bool(args["dry-run"])
36862
37041
  };
36863
37042
  }
36864
- var normalizeCommand2 = defineCommand143({
37043
+ var normalizeCommand2 = defineCommand144({
36865
37044
  meta: {
36866
37045
  name: "normalize",
36867
37046
  description: `Normalize logos / images: declarative recolor + bg removal + trim + resize. Operates on local files; writes in-place by default.
@@ -36916,7 +37095,7 @@ Examples:
36916
37095
  });
36917
37096
 
36918
37097
  // src/commands/images/pinterest.ts
36919
- import { defineCommand as defineCommand144 } from "citty";
37098
+ import { defineCommand as defineCommand145 } from "citty";
36920
37099
  registerSchema({
36921
37100
  command: "images.pinterest",
36922
37101
  description: "Pinterest image search via ScrapeCreators. Reference-grade real-world photography, product styling, interiors, fashion, food, and aesthetic mood boards. Inspect before placing \u2014 Pinterest is unverified, trademark-bearing web content.",
@@ -36936,7 +37115,7 @@ registerSchema({
36936
37115
  }
36937
37116
  }
36938
37117
  });
36939
- var pinterestCommand = defineCommand144({
37118
+ var pinterestCommand = defineCommand145({
36940
37119
  meta: {
36941
37120
  name: "pinterest",
36942
37121
  description: "Pinterest image search via ScrapeCreators ($0.00188/request). Best for photo-realistic reference imagery \u2014 lifestyle, interiors, fashion, food, product styling, and mood boards to brief AI generation against. \u26A0 Unverified, trademark-bearing web content \u2014 inspect and respect rights before placing on a customer page. Browse first; auto-ingest only the pins you commit to.\n\nExamples:\n baker images pinterest 'scandinavian living room'\n baker images pinterest 'minimalist skincare product photography' --limit 20\n baker images pinterest 'cozy coffee shop interior' --auto-ingest 2 --context 'Mood reference for hero photography'"
@@ -36993,7 +37172,7 @@ var pinterestCommand = defineCommand144({
36993
37172
  });
36994
37173
 
36995
37174
  // src/commands/images/screenshot.ts
36996
- import { defineCommand as defineCommand145 } from "citty";
37175
+ import { defineCommand as defineCommand146 } from "citty";
36997
37176
  registerSchema({
36998
37177
  command: "images.screenshot",
36999
37178
  description: "Capture a website screenshot via ScreenshotOne. Auto-ingests on success.",
@@ -37012,7 +37191,7 @@ registerSchema({
37012
37191
  full: { type: "boolean", description: "Include full metadata", required: false, default: false }
37013
37192
  }
37014
37193
  });
37015
- var screenshotCommand = defineCommand145({
37194
+ var screenshotCommand = defineCommand146({
37016
37195
  meta: {
37017
37196
  name: "screenshot",
37018
37197
  description: "Screenshot a URL via ScreenshotOne. $0.009/capture. Auto-ingests to library.\n\nExample: baker images screenshot https://stripe.com --full-page"
@@ -37076,7 +37255,7 @@ var screenshotCommand = defineCommand145({
37076
37255
  });
37077
37256
 
37078
37257
  // src/commands/images/search.ts
37079
- import { defineCommand as defineCommand146 } from "citty";
37258
+ import { defineCommand as defineCommand147 } from "citty";
37080
37259
  registerSchema({
37081
37260
  command: "images.search",
37082
37261
  description: "Search images by text query. Only returns ready images.",
@@ -37092,7 +37271,7 @@ registerSchema({
37092
37271
  tags: { type: "string", description: "Comma-separated tags to filter by", required: false }
37093
37272
  }
37094
37273
  });
37095
- var searchCommand = defineCommand146({
37274
+ var searchCommand = defineCommand147({
37096
37275
  meta: {
37097
37276
  name: "search",
37098
37277
  description: "Semantic search images by text query. Uses hybrid BM25 + vector + reranking. Example: baker images search 'hero banner' --aspect-ratio 16:9 --tags logo"
@@ -37152,7 +37331,7 @@ var searchCommand = defineCommand146({
37152
37331
  });
37153
37332
 
37154
37333
  // src/commands/images/sticker.ts
37155
- import { defineCommand as defineCommand147 } from "citty";
37334
+ import { defineCommand as defineCommand148 } from "citty";
37156
37335
  registerSchema({
37157
37336
  command: "images.sticker",
37158
37337
  description: "Search Giphy stickers \u2014 transparent-background overlays for ad creative.",
@@ -37184,7 +37363,7 @@ registerSchema({
37184
37363
  }
37185
37364
  }
37186
37365
  });
37187
- var stickerCommand = defineCommand147({
37366
+ var stickerCommand = defineCommand148({
37188
37367
  meta: {
37189
37368
  name: "sticker",
37190
37369
  description: "Search Giphy's sticker corpus \u2014 transparent-background WebPs / GIFs ideal for overlaying on ad creative (Meta, TikTok, Stories). Same Giphy free API as `baker images gif`; results carry WebP + GIF + MP4 URLs in providerMeta.\n\nExample: baker images sticker 'thumbs up' --limit 10\nExample: baker images sticker celebration --rating g --auto-ingest 3\nExample: baker images sticker --trending --limit 25"
@@ -37231,7 +37410,7 @@ var stickerCommand = defineCommand147({
37231
37410
  });
37232
37411
 
37233
37412
  // src/commands/images/stock.ts
37234
- import { defineCommand as defineCommand148 } from "citty";
37413
+ import { defineCommand as defineCommand149 } from "citty";
37235
37414
  var STOCK_ERROR_FIX = {
37236
37415
  action: "use_different_resource",
37237
37416
  explanation: "Switch provider instead of retrying stock search. Stock search is one of several image sources. Run `baker images find <query> --sources library,pinterest,google` (`--sources` is required \u2014 `find` alone searches the library only) or `baker studio generate` to make the asset. Never sleep-and-retry this command \u2014 the CLI already backs off on rate limits. If no image can be sourced, continue the rest of the task with a placeholder rather than aborting it."
@@ -37308,7 +37487,7 @@ function buildStockRequest(query, args) {
37308
37487
  if (args.context) body.descriptionContext = args.context;
37309
37488
  return body;
37310
37489
  }
37311
- var stockCommand = defineCommand148({
37490
+ var stockCommand = defineCommand149({
37312
37491
  meta: {
37313
37492
  name: "stock",
37314
37493
  description: "Stock search via Magnific \u2014 Freepik's developer API (~250M assets: photos, vectors, illustrations, icons, PSDs). $0.002/req. With --auto-ingest, ingested hits return Baker-owned URLs.\n\nExamples:\n baker images stock 'minimalist office'\n baker images stock 'flat office workers' --type vector\n baker images stock 'hero photo of a kitchen' --type photo --orientation landscape --ai exclude\n baker images stock 'brand pattern' --color '#0a0a0a' --license freemium --auto-ingest 2"
@@ -37381,7 +37560,7 @@ var stockCommand = defineCommand148({
37381
37560
  });
37382
37561
 
37383
37562
  // src/lib/tags-command.ts
37384
- import { defineCommand as defineCommand149 } from "citty";
37563
+ import { defineCommand as defineCommand150 } from "citty";
37385
37564
  function makeTagsCommand(command, label, endpoint) {
37386
37565
  registerSchema({
37387
37566
  command: `${command}.tags`,
@@ -37390,7 +37569,7 @@ function makeTagsCommand(command, label, endpoint) {
37390
37569
  output: { type: "string", description: "Output format: md|json", required: false, default: "md" }
37391
37570
  }
37392
37571
  });
37393
- return defineCommand149({
37572
+ return defineCommand150({
37394
37573
  meta: {
37395
37574
  name: "tags",
37396
37575
  description: `List the available ${label} tag names (defaults + company custom tags). Use before filtering with --tags. Example: baker ${command} tags`
@@ -37426,7 +37605,7 @@ function makeTagsCommand(command, label, endpoint) {
37426
37605
  var tagsCommand2 = makeTagsCommand("images", "image", "/api/images/tags");
37427
37606
 
37428
37607
  // src/commands/images/upload.ts
37429
- import { defineCommand as defineCommand150 } from "citty";
37608
+ import { defineCommand as defineCommand151 } from "citty";
37430
37609
  registerSchema({
37431
37610
  command: "images.upload",
37432
37611
  description: "Upload an image to the library \u2014 local file path or remote http(s) URL.",
@@ -37464,7 +37643,7 @@ registerSchema({
37464
37643
  function isRemoteUrl2(value) {
37465
37644
  return /^https?:\/\//i.test(value);
37466
37645
  }
37467
- var uploadCommand = defineCommand150({
37646
+ var uploadCommand = defineCommand151({
37468
37647
  meta: {
37469
37648
  name: "upload",
37470
37649
  description: "Upload an image to the library \u2014 accepts a local file path OR a remote http(s) URL.\n\nLocal: reads bytes, sends to /api/images/upload, content-type auto-detected from extension.\nRemote: dispatches to /api/images/ingest with hash-dedup on bytes + externalId.\n\nExamples:\n baker images upload ./logo.png --source uploaded\n baker images upload ./cert.png --context 'ISO 27001 badge \u2014 enterprise tier'\n baker images upload https://acme.com/hero.png --source firecrawl --context 'Acme competitor pricing hero'"
@@ -37557,7 +37736,7 @@ async function uploadLocal(target, args) {
37557
37736
  }
37558
37737
 
37559
37738
  // src/commands/images/upscale.ts
37560
- import { defineCommand as defineCommand151 } from "citty";
37739
+ import { defineCommand as defineCommand152 } from "citty";
37561
37740
  registerSchema({
37562
37741
  command: "images.upscale",
37563
37742
  description: "Upscale a library image via the backend (Replicate, cost-tracked). Waits for completion by default. The image must be status 'ready' and raster (not SVG/AVIF).",
@@ -37572,7 +37751,7 @@ registerSchema({
37572
37751
  }
37573
37752
  });
37574
37753
  var POLL_INTERVAL_MS4 = 1500;
37575
- var upscaleCommand = defineCommand151({
37754
+ var upscaleCommand = defineCommand152({
37576
37755
  meta: {
37577
37756
  name: "upscale",
37578
37757
  description: "Upscale a library image via the Convex backend (Replicate, cost-tracked at $0.05/image). Waits for completion by default.\n\nExample: baker images upscale j571abc123def\nExample: baker images upscale j571abc123def --max-wait 0 # fire-and-forget"
@@ -37627,7 +37806,7 @@ var upscaleCommand = defineCommand151({
37627
37806
  });
37628
37807
 
37629
37808
  // src/commands/images/use.ts
37630
- import { defineCommand as defineCommand152 } from "citty";
37809
+ import { defineCommand as defineCommand153 } from "citty";
37631
37810
  registerSchema({
37632
37811
  command: "images.use",
37633
37812
  description: "Ingest a URL and wait for the library record to be ready.",
@@ -37656,7 +37835,7 @@ function emitReady(ingestResult, doc, args) {
37656
37835
  args.full === true
37657
37836
  );
37658
37837
  }
37659
- var useCommand = defineCommand152({
37838
+ var useCommand = defineCommand153({
37660
37839
  meta: {
37661
37840
  name: "use",
37662
37841
  description: "Sugar over `ingest`: download \u2192 store \u2192 wait until describe + embed complete \u2192 return ready library record.\n\nExample: baker images use https://cdn.example.com/hero.png --source uploaded"
@@ -37705,7 +37884,7 @@ var useCommand = defineCommand152({
37705
37884
  });
37706
37885
 
37707
37886
  // src/commands/images/index.ts
37708
- var imagesCommand = defineCommand153({
37887
+ var imagesCommand = defineCommand154({
37709
37888
  meta: {
37710
37889
  name: "images",
37711
37890
  description: `Find, source, and normalize images. Subcommands route by provider so cost + license are explicit.
@@ -37783,12 +37962,12 @@ Full guide: __tooling__/docs/tools/baker/images.md`
37783
37962
  });
37784
37963
 
37785
37964
  // src/commands/landing/index.ts
37786
- import { defineCommand as defineCommand164 } from "citty";
37965
+ import { defineCommand as defineCommand165 } from "citty";
37787
37966
 
37788
37967
  // src/commands/landing/critique.ts
37789
37968
  import { readdir as readdir9, stat as stat6 } from "fs/promises";
37790
37969
  import path29 from "path";
37791
- import { defineCommand as defineCommand154 } from "citty";
37970
+ import { defineCommand as defineCommand155 } from "citty";
37792
37971
 
37793
37972
  // src/engine/landing/lib/constants.ts
37794
37973
  var OVERUSED_FONTS = /* @__PURE__ */ new Set([
@@ -38971,7 +39150,7 @@ function fail5(code, message, fix) {
38971
39150
  );
38972
39151
  process.exit(2);
38973
39152
  }
38974
- var critiqueCommand2 = defineCommand154({
39153
+ var critiqueCommand2 = defineCommand155({
38975
39154
  meta: {
38976
39155
  name: "critique",
38977
39156
  description: "Start here: `baker landing critique <slug>` after building or editing a landing. Deterministic design-quality critic (ADVISORY \u2014 findings never fail it). Flags the known AI design tells (gradient text, overused fonts, side-tab borders, cream palettes, buzzword copy, broken images) tiered block/warn/advisory, respecting the client's BRAND.md as the allowlist. Also records the critique that publishing requires \u2014 run it before finishing a landing."
@@ -39080,10 +39259,10 @@ async function isDir(p) {
39080
39259
  }
39081
39260
 
39082
39261
  // src/commands/landing/inspiration/index.ts
39083
- import { defineCommand as defineCommand163 } from "citty";
39262
+ import { defineCommand as defineCommand164 } from "citty";
39084
39263
 
39085
39264
  // src/commands/landing/inspiration/add.ts
39086
- import { defineCommand as defineCommand155 } from "citty";
39265
+ import { defineCommand as defineCommand156 } from "citty";
39087
39266
 
39088
39267
  // src/commands/landing/inspiration/shared.ts
39089
39268
  var INSPIRATION_HINTS = {
@@ -39165,7 +39344,7 @@ registerSchema({
39165
39344
  note: { type: "string", description: "Why this page is worth keeping", required: false }
39166
39345
  }
39167
39346
  });
39168
- var addCommand = defineCommand155({
39347
+ var addCommand = defineCommand156({
39169
39348
  meta: {
39170
39349
  name: "add",
39171
39350
  description: "Add someone else's landing page to the reference library. Example: baker landing inspiration add https://linear.app --note 'the client likes this density'"
@@ -39207,7 +39386,7 @@ var addCommand = defineCommand155({
39207
39386
  // src/commands/landing/inspiration/code.ts
39208
39387
  import { mkdir as mkdir10, writeFile as writeFile14 } from "fs/promises";
39209
39388
  import path30 from "path";
39210
- import { defineCommand as defineCommand156 } from "citty";
39389
+ import { defineCommand as defineCommand157 } from "citty";
39211
39390
  registerSchema({
39212
39391
  command: "landing.inspiration.code",
39213
39392
  description: "Write a reference section's standalone HTML+CSS to .baker/inspiration/<id>/ so you can read how it is built. Reference only \u2014 the structure is the lesson, the words are not yours to reuse. Consulting a section records it, and `baker landing critique` blocks a publish that ships its copy verbatim.",
@@ -39216,7 +39395,7 @@ registerSchema({
39216
39395
  full: { type: "boolean", description: "Print the markup inline as well as writing it", required: false }
39217
39396
  }
39218
39397
  });
39219
- var codeCommand = defineCommand156({
39398
+ var codeCommand = defineCommand157({
39220
39399
  meta: {
39221
39400
  name: "code",
39222
39401
  description: "Write one reference section's standalone markup to disk. Example: baker landing inspiration code k57abc\u2026 \u2014 read it for structure, then build your own."
@@ -39273,7 +39452,7 @@ var codeCommand = defineCommand156({
39273
39452
  });
39274
39453
 
39275
39454
  // src/commands/landing/inspiration/favorites.ts
39276
- import { defineCommand as defineCommand157 } from "citty";
39455
+ import { defineCommand as defineCommand158 } from "citty";
39277
39456
  registerSchema({
39278
39457
  command: "landing.inspiration.favorites",
39279
39458
  description: "List the reference sections this company has saved. This is what `search` looks at by default, so it is the client's own taste profile \u2014 read it before proposing a direction.",
@@ -39287,7 +39466,7 @@ registerSchema({
39287
39466
  }
39288
39467
  }
39289
39468
  });
39290
- var favoritesCommand = defineCommand157({
39469
+ var favoritesCommand = defineCommand158({
39291
39470
  meta: {
39292
39471
  name: "favorites",
39293
39472
  description: "List this company's saved reference sections. Example: baker landing inspiration favorites --type hero,pricing"
@@ -39367,7 +39546,7 @@ registerSchema({
39367
39546
  note: { type: "string", description: "Why this is worth keeping", required: false }
39368
39547
  }
39369
39548
  });
39370
- var favoriteCommand = defineCommand157({
39549
+ var favoriteCommand = defineCommand158({
39371
39550
  meta: {
39372
39551
  name: "favorite",
39373
39552
  description: "Save a reference section to this company. Example: baker landing inspiration favorite k57abc\u2026"
@@ -39405,7 +39584,7 @@ registerSchema({
39405
39584
  page: { type: "boolean", description: "Treat the id as a page rather than a section", required: false }
39406
39585
  }
39407
39586
  });
39408
- var unfavoriteCommand = defineCommand157({
39587
+ var unfavoriteCommand = defineCommand158({
39409
39588
  meta: {
39410
39589
  name: "unfavorite",
39411
39590
  description: "Remove a reference section from this company's saved set. Example: baker landing inspiration unfavorite k57abc\u2026"
@@ -39427,7 +39606,7 @@ var unfavoriteCommand = defineCommand157({
39427
39606
  });
39428
39607
 
39429
39608
  // src/commands/landing/inspiration/page.ts
39430
- import { defineCommand as defineCommand158 } from "citty";
39609
+ import { defineCommand as defineCommand159 } from "citty";
39431
39610
  registerSchema({
39432
39611
  command: "landing.inspiration.page",
39433
39612
  description: "Show a whole reference page as a sequence: every section top to bottom with its type and the idea behind it. This is the view to use when the question is how a good page is ORDERED rather than what one section looks like.",
@@ -39444,7 +39623,7 @@ registerSchema({
39444
39623
  }
39445
39624
  }
39446
39625
  });
39447
- var pageCommand = defineCommand158({
39626
+ var pageCommand = defineCommand159({
39448
39627
  meta: {
39449
39628
  name: "page",
39450
39629
  description: "Show how a reference page sequences its sections. Example: baker landing inspiration page j91xyz\u2026 \u2014 the blueprint, not the pixels."
@@ -39509,7 +39688,7 @@ var pageCommand = defineCommand158({
39509
39688
  // src/commands/landing/inspiration/scrape.ts
39510
39689
  import { readFile as readFile23 } from "fs/promises";
39511
39690
  import path33 from "path";
39512
- import { defineCommand as defineCommand159 } from "citty";
39691
+ import { defineCommand as defineCommand160 } from "citty";
39513
39692
 
39514
39693
  // src/engine/landing/lib/capturedReferences.ts
39515
39694
  var MAX_STRINGS_PER_SECTION = 40;
@@ -41650,7 +41829,7 @@ registerSchema({
41650
41829
  report: { type: "boolean", description: "Write report.html. `--no-report` to skip", required: false }
41651
41830
  }
41652
41831
  });
41653
- var scrapeCommand = defineCommand159({
41832
+ var scrapeCommand = defineCommand160({
41654
41833
  meta: {
41655
41834
  name: "scrape",
41656
41835
  description: "Capture a landing page to a directory, now. Example: baker landing inspiration scrape https://linear.app --out .baker/inspiration/linear.app"
@@ -41752,7 +41931,7 @@ var scrapeCommand = defineCommand159({
41752
41931
 
41753
41932
  // src/commands/landing/inspiration/search.ts
41754
41933
  import path35 from "path";
41755
- import { defineCommand as defineCommand160 } from "citty";
41934
+ import { defineCommand as defineCommand161 } from "citty";
41756
41935
 
41757
41936
  // src/commands/landing/inspiration/shot.ts
41758
41937
  import { mkdir as mkdir12, writeFile as writeFile17 } from "fs/promises";
@@ -41889,7 +42068,7 @@ async function downloadShots(results) {
41889
42068
  );
41890
42069
  return saved;
41891
42070
  }
41892
- var searchCommand2 = defineCommand160({
42071
+ var searchCommand2 = defineCommand161({
41893
42072
  meta: {
41894
42073
  name: "search",
41895
42074
  description: "Search real landing-page sections for reference. Example: baker landing inspiration search 'dark developer hero with a terminal' --register dev-tool-minimal --scope all"
@@ -41987,7 +42166,7 @@ var searchCommand2 = defineCommand160({
41987
42166
  });
41988
42167
 
41989
42168
  // src/commands/landing/inspiration/sequences.ts
41990
- import { defineCommand as defineCommand161 } from "citty";
42169
+ import { defineCommand as defineCommand162 } from "citty";
41991
42170
  var COMPACT_TRANSITIONS = 12;
41992
42171
  var COMPACT_ENDS = 5;
41993
42172
  var MAX_PAGES = 50;
@@ -42061,7 +42240,7 @@ function sequencesHints(data, { scope, full }) {
42061
42240
  if (scope === "favorites") hints.push(...favoritesScopeHints(data.favoritesHealth, data.pagesReturned));
42062
42241
  return hints;
42063
42242
  }
42064
- var sequencesCommand = defineCommand161({
42243
+ var sequencesCommand = defineCommand162({
42065
42244
  meta: {
42066
42245
  name: "sequences",
42067
42246
  description: "What section follows what, across many real pages at once. Example: baker landing inspiration sequences 'developer tool pricing page' --scope all \u2014 the evidence for how to order a page you are about to build."
@@ -42111,7 +42290,7 @@ var sequencesCommand = defineCommand161({
42111
42290
 
42112
42291
  // src/commands/landing/inspiration/view.ts
42113
42292
  import path36 from "path";
42114
- import { defineCommand as defineCommand162 } from "citty";
42293
+ import { defineCommand as defineCommand163 } from "citty";
42115
42294
  registerSchema({
42116
42295
  command: "landing.inspiration.view",
42117
42296
  description: "Everything known about one section: composition, motion, design tokens, the copy it uses, why it works, and what must change to make it yours. Downloads the desktop and mobile screenshots plus the motion filmstrip so you can look at them.",
@@ -42124,7 +42303,7 @@ registerSchema({
42124
42303
  }
42125
42304
  }
42126
42305
  });
42127
- var viewCommand2 = defineCommand162({
42306
+ var viewCommand2 = defineCommand163({
42128
42307
  meta: {
42129
42308
  name: "view",
42130
42309
  description: "Full detail for one reference section. Example: baker landing inspiration view k57abc\u2026 \u2014 read the screenshots it saves before you build."
@@ -42208,7 +42387,7 @@ var viewCommand2 = defineCommand162({
42208
42387
  });
42209
42388
 
42210
42389
  // src/commands/landing/inspiration/index.ts
42211
- var inspirationCommand = defineCommand163({
42390
+ var inspirationCommand = defineCommand164({
42212
42391
  meta: {
42213
42392
  name: "inspiration",
42214
42393
  description: `Reference library of real landing-page sections \u2014 look at how good pages actually solve a problem before you design one.
@@ -42253,7 +42432,7 @@ Full guide: __tooling__/docs/tools/baker/landing.md`
42253
42432
  });
42254
42433
 
42255
42434
  // src/commands/landing/index.ts
42256
- var landingCommand = defineCommand164({
42435
+ var landingCommand = defineCommand165({
42257
42436
  meta: {
42258
42437
  name: "landing",
42259
42438
  description: `Design-quality tools for landing pages (src/pages/<slug>/).
@@ -42271,7 +42450,7 @@ Subcommands:
42271
42450
  });
42272
42451
 
42273
42452
  // src/commands/mcp/index.ts
42274
- import { defineCommand as defineCommand165 } from "citty";
42453
+ import { defineCommand as defineCommand166 } from "citty";
42275
42454
 
42276
42455
  // src/commands/mcp/platforms.ts
42277
42456
  function readsKey(label) {
@@ -42340,7 +42519,7 @@ registerSchema({
42340
42519
  description: "List everything this chat can reach: managed integrations (Attio, Slack, Gmail, Google Sheets, \u2026), custom MCP servers, and the platforms the company signed in to (HubSpot, Google Ads, GA4, Search Console, Tag Manager) which you read through their own `baker` commands. Start here when the user mentions an external tool or platform.",
42341
42520
  args: {}
42342
42521
  });
42343
- var connectedCommand = defineCommand165({
42522
+ var connectedCommand = defineCommand166({
42344
42523
  meta: {
42345
42524
  name: "connected",
42346
42525
  description: `Everything this chat can reach \u2014 managed integrations, custom MCP servers, and connected platforms.
@@ -42399,7 +42578,7 @@ registerSchema({
42399
42578
  description: "List the custom MCP servers this company's chats see (org + company + your own user scope).",
42400
42579
  args: {}
42401
42580
  });
42402
- var listCommand14 = defineCommand165({
42581
+ var listCommand14 = defineCommand166({
42403
42582
  meta: { name: "list", description: "List custom MCP servers visible to this company's chats." },
42404
42583
  run: async () => {
42405
42584
  try {
@@ -42436,7 +42615,7 @@ registerSchema({
42436
42615
  header: { type: "string", description: 'Auth header "Key: Value" (repeatable)', required: false }
42437
42616
  }
42438
42617
  });
42439
- var addCommand2 = defineCommand165({
42618
+ var addCommand2 = defineCommand166({
42440
42619
  meta: {
42441
42620
  name: "add",
42442
42621
  description: `Register a custom MCP server. Tools appear as mcp__<name>__* on the NEXT message.
@@ -42488,7 +42667,7 @@ registerSchema({
42488
42667
  description: "Remove a company custom MCP server by name.",
42489
42668
  args: { name: { type: "string", description: "Server name to remove", required: true } }
42490
42669
  });
42491
- var removeCommand4 = defineCommand165({
42670
+ var removeCommand4 = defineCommand166({
42492
42671
  meta: {
42493
42672
  name: "remove",
42494
42673
  description: `Remove a company custom MCP server by name.
@@ -42510,7 +42689,7 @@ Example:
42510
42689
  }
42511
42690
  }
42512
42691
  });
42513
- var mcpCommand = defineCommand165({
42692
+ var mcpCommand = defineCommand166({
42514
42693
  meta: {
42515
42694
  name: "mcp",
42516
42695
  description: `Third-party tools for this company \u2014 see what's connected, register custom HTTPS MCP endpoints.
@@ -42536,10 +42715,10 @@ Full guide: __tooling__/docs/tools/baker/mcp.md`
42536
42715
  });
42537
42716
 
42538
42717
  // src/commands/research/index.ts
42539
- import { defineCommand as defineCommand177 } from "citty";
42718
+ import { defineCommand as defineCommand178 } from "citty";
42540
42719
 
42541
42720
  // src/commands/research/advertisers.ts
42542
- import { defineCommand as defineCommand166 } from "citty";
42721
+ import { defineCommand as defineCommand167 } from "citty";
42543
42722
 
42544
42723
  // src/commands/research/hints.ts
42545
42724
  var AD_COPY_ROUTE = 'This returns competing DOMAINS and their SERP economics \u2014 no ad copy, no headlines, no creative. For the actual copy of a competitor\'s ads: `baker winning-ads advertisers "<brand>"` \u2192 `baker winning-ads search "<brief>" --advertiser-id <id>` \u2192 `baker winning-ads content <adId>` (`primary_text` / `headline` / `cta`, plus the spoken transcript and on-screen text for video). That corpus is Meta and LinkedIn only \u2014 Google SERP ad copy is not available through any Baker command, so do not keep querying for it here.';
@@ -42722,7 +42901,7 @@ var FIELDS3 = {
42722
42901
  etv: "Estimated traffic value (USD)",
42723
42902
  visibility: "SERP visibility score (0-1)"
42724
42903
  };
42725
- var advertisersCommand = defineCommand166({
42904
+ var advertisersCommand = defineCommand167({
42726
42905
  meta: {
42727
42906
  name: "advertisers",
42728
42907
  description: `Domains competing for a keyword in Google SERPs, with position, relevance, traffic value and visibility. Returns NO ad copy \u2014 for a competitor's headlines and body copy use \`baker winning-ads content <adId>\` (Meta/LinkedIn only).
@@ -42778,7 +42957,7 @@ Examples:
42778
42957
  });
42779
42958
 
42780
42959
  // src/commands/research/autocomplete.ts
42781
- import { defineCommand as defineCommand167 } from "citty";
42960
+ import { defineCommand as defineCommand168 } from "citty";
42782
42961
  registerSchema({
42783
42962
  command: "research.autocomplete",
42784
42963
  description: "Get Google Autocomplete suggestions for a seed keyword. Useful for keyword expansion and discovering what people actually search for. IMPORTANT: If --location and --language are omitted, defaults to United States (us) and English (en).",
@@ -42801,7 +42980,7 @@ registerSchema({
42801
42980
  var FIELDS4 = {
42802
42981
  suggestion: "Autocomplete suggestion from Google"
42803
42982
  };
42804
- var autocompleteCommand = defineCommand167({
42983
+ var autocompleteCommand = defineCommand168({
42805
42984
  meta: {
42806
42985
  name: "autocomplete",
42807
42986
  description: `Get Google Autocomplete suggestions for keyword expansion.
@@ -42856,7 +43035,7 @@ Examples:
42856
43035
  });
42857
43036
 
42858
43037
  // src/commands/research/countries.ts
42859
- import { defineCommand as defineCommand168 } from "citty";
43038
+ import { defineCommand as defineCommand169 } from "citty";
42860
43039
  registerSchema({
42861
43040
  command: "research.countries",
42862
43041
  description: "List all supported country codes for --location flag in research commands.",
@@ -42913,7 +43092,7 @@ var FIELDS5 = {
42913
43092
  code: "Country code to pass as --location",
42914
43093
  name: "Country name"
42915
43094
  };
42916
- var countriesCommand = defineCommand168({
43095
+ var countriesCommand = defineCommand169({
42917
43096
  meta: {
42918
43097
  name: "countries",
42919
43098
  description: "List all supported country codes for --location flag."
@@ -42924,7 +43103,7 @@ var countriesCommand = defineCommand168({
42924
43103
  });
42925
43104
 
42926
43105
  // src/commands/research/fetch.ts
42927
- import { defineCommand as defineCommand169 } from "citty";
43106
+ import { defineCommand as defineCommand170 } from "citty";
42928
43107
  var CONTENT_PREVIEW_CHARS = 2e4;
42929
43108
  var TIMEOUT_MS = 18e4;
42930
43109
  registerSchema({
@@ -42997,7 +43176,7 @@ function fetchFix(code) {
42997
43176
  explanation: "This read failed. Don't build a retry ladder around it \u2014 finish the rest of the job with what you can reach and name this page as a gap."
42998
43177
  };
42999
43178
  }
43000
- var fetchCommand = defineCommand169({
43179
+ var fetchCommand = defineCommand170({
43001
43180
  meta: {
43002
43181
  name: "fetch",
43003
43182
  description: `Read a page an ordinary web fetch could not. Bot walls and JavaScript-rendered pages are resolved for you \u2014 you never have to retry, wait, or drive a browser yourself.
@@ -43074,7 +43253,7 @@ Examples:
43074
43253
  });
43075
43254
 
43076
43255
  // src/commands/research/intent.ts
43077
- import { defineCommand as defineCommand170 } from "citty";
43256
+ import { defineCommand as defineCommand171 } from "citty";
43078
43257
  registerSchema({
43079
43258
  command: "research.intent",
43080
43259
  description: "Classify Google Search intent for keywords. Determines if someone searching is looking to buy, research, or navigate. IMPORTANT: If --language is omitted, defaults to English (en). The response includes a query_context object showing which language was used.",
@@ -43097,7 +43276,7 @@ var FIELDS7 = {
43097
43276
  intent: "Primary Google Search intent: informational, navigational, commercial, transactional",
43098
43277
  probability: "Confidence score 0.0-1.0"
43099
43278
  };
43100
- var intentCommand = defineCommand170({
43279
+ var intentCommand = defineCommand171({
43101
43280
  meta: {
43102
43281
  name: "intent",
43103
43282
  description: `Classify Google Search intent for keywords. Returns intent type and confidence.
@@ -43145,7 +43324,7 @@ Examples:
43145
43324
  });
43146
43325
 
43147
43326
  // src/commands/research/keyword-gap.ts
43148
- import { defineCommand as defineCommand171 } from "citty";
43327
+ import { defineCommand as defineCommand172 } from "citty";
43149
43328
  registerSchema({
43150
43329
  command: "research.keyword-gap",
43151
43330
  description: "Find keywords a competitor ranks for (organic or paid) that you don't. Discovers expansion opportunities. IMPORTANT: If --location and --language are omitted, defaults to United States (us) and English (en). The response includes a query_context object showing which location/language were used.",
@@ -43174,7 +43353,7 @@ var FIELDS8 = {
43174
43353
  cpc: "Cost per click USD",
43175
43354
  their_position: "Competitor's ranking position"
43176
43355
  };
43177
- var keywordGapCommand = defineCommand171({
43356
+ var keywordGapCommand = defineCommand172({
43178
43357
  meta: {
43179
43358
  name: "keyword-gap",
43180
43359
  description: `Find keywords a competitor has that you don't. Supports pagination via --offset.
@@ -43249,7 +43428,7 @@ Examples:
43249
43428
  });
43250
43429
 
43251
43430
  // src/commands/research/keywords-for-site.ts
43252
- import { defineCommand as defineCommand172 } from "citty";
43431
+ import { defineCommand as defineCommand173 } from "citty";
43253
43432
  registerSchema({
43254
43433
  command: "research.keywords-for-site",
43255
43434
  description: "Get keywords a competitor targets in Google. Use --type paid to see only paid keywords, --type organic for organic only. IMPORTANT: If --location and --language are omitted, defaults to United States (us) and English (en). The response includes a query_context object showing which location/language were used.",
@@ -43282,7 +43461,7 @@ var FIELDS9 = {
43282
43461
  competition: "LOW, MEDIUM, or HIGH",
43283
43462
  competition_index: "Competition score 0-100"
43284
43463
  };
43285
- var keywordsForSiteCommand = defineCommand172({
43464
+ var keywordsForSiteCommand = defineCommand173({
43286
43465
  meta: {
43287
43466
  name: "keywords-for-site",
43288
43467
  description: `Get keywords a competitor targets in Google. Use --type to filter paid/organic.
@@ -43344,7 +43523,7 @@ Examples:
43344
43523
  });
43345
43524
 
43346
43525
  // src/commands/research/languages.ts
43347
- import { defineCommand as defineCommand173 } from "citty";
43526
+ import { defineCommand as defineCommand174 } from "citty";
43348
43527
  registerSchema({
43349
43528
  command: "research.languages",
43350
43529
  description: "List all supported language codes for --language flag in research commands.",
@@ -43374,7 +43553,7 @@ var FIELDS10 = {
43374
43553
  code: "Language code to pass as --language",
43375
43554
  name: "Language name (also accepted by --language)"
43376
43555
  };
43377
- var languagesCommand2 = defineCommand173({
43556
+ var languagesCommand2 = defineCommand174({
43378
43557
  meta: {
43379
43558
  name: "languages",
43380
43559
  description: "List all supported language codes for --language flag."
@@ -43385,7 +43564,7 @@ var languagesCommand2 = defineCommand173({
43385
43564
  });
43386
43565
 
43387
43566
  // src/commands/research/lighthouse.ts
43388
- import { defineCommand as defineCommand174 } from "citty";
43567
+ import { defineCommand as defineCommand175 } from "citty";
43389
43568
  registerSchema({
43390
43569
  command: "research.lighthouse",
43391
43570
  description: "Landing page performance audit. Returns metrics that affect Google Ads Quality Score and CPC.",
@@ -43404,7 +43583,7 @@ var FIELDS11 = {
43404
43583
  speed_index_ms: "Speed Index in ms (good: < 3400)",
43405
43584
  interactive_ms: "Time to Interactive in ms (good: < 3800)"
43406
43585
  };
43407
- var lighthouseCommand = defineCommand174({
43586
+ var lighthouseCommand = defineCommand175({
43408
43587
  meta: {
43409
43588
  name: "lighthouse",
43410
43589
  description: `Landing page performance audit. Metrics affecting Google Ads Quality Score.
@@ -43442,7 +43621,7 @@ Examples:
43442
43621
  });
43443
43622
 
43444
43623
  // src/commands/research/relevant-pages.ts
43445
- import { defineCommand as defineCommand175 } from "citty";
43624
+ import { defineCommand as defineCommand176 } from "citty";
43446
43625
  registerSchema({
43447
43626
  command: "research.relevant-pages",
43448
43627
  description: "Get the top pages of a competitor domain with organic traffic and ranking data. Shows which pages drive the most traffic. IMPORTANT: If --location and --language are omitted, defaults to United States (us) and English (en).",
@@ -43468,7 +43647,7 @@ var FIELDS12 = {
43468
43647
  keywords: "Total organic keywords the page ranks for",
43469
43648
  top_10: "Keywords in positions 1-10"
43470
43649
  };
43471
- var relevantPagesCommand = defineCommand175({
43650
+ var relevantPagesCommand = defineCommand176({
43472
43651
  meta: {
43473
43652
  name: "relevant-pages",
43474
43653
  description: `Get the top pages of a competitor domain with traffic data.
@@ -43515,7 +43694,7 @@ Examples:
43515
43694
  });
43516
43695
 
43517
43696
  // src/commands/research/web.ts
43518
- import { defineCommand as defineCommand176 } from "citty";
43697
+ import { defineCommand as defineCommand177 } from "citty";
43519
43698
  registerSchema({
43520
43699
  command: "research.web",
43521
43700
  description: "Search the web with AI to answer marketing questions \u2014 competitors, ICP, pricing, pain points, market trends. Three depth levels: medium (quick, default), high (thorough), xhigh (exhaustive deep research).",
@@ -43566,7 +43745,7 @@ async function runDeepResearch(question) {
43566
43745
  }
43567
43746
  throw new Error("Deep research timed out");
43568
43747
  }
43569
- var webCommand = defineCommand176({
43748
+ var webCommand = defineCommand177({
43570
43749
  meta: {
43571
43750
  name: "web",
43572
43751
  description: `Search the web with AI to answer any open-ended marketing question. Uses live internet data via Google Search.
@@ -43628,7 +43807,7 @@ Examples:
43628
43807
  });
43629
43808
 
43630
43809
  // src/commands/research/index.ts
43631
- var researchCommand = defineCommand177({
43810
+ var researchCommand = defineCommand178({
43632
43811
  meta: {
43633
43812
  name: "research",
43634
43813
  description: `Competitive intelligence and AI-powered research commands.
@@ -43672,10 +43851,10 @@ Full guide: __tooling__/docs/tools/baker/research.md`
43672
43851
  });
43673
43852
 
43674
43853
  // src/commands/scheduled-actions/index.ts
43675
- import { defineCommand as defineCommand185 } from "citty";
43854
+ import { defineCommand as defineCommand186 } from "citty";
43676
43855
 
43677
43856
  // src/commands/scheduled-actions/create.ts
43678
- import { defineCommand as defineCommand178 } from "citty";
43857
+ import { defineCommand as defineCommand179 } from "citty";
43679
43858
 
43680
43859
  // src/commands/scheduled-actions/shared.ts
43681
43860
  var TEMP_SCHEDULED_ACTION_PREFIX = "temp_sched_";
@@ -43822,7 +44001,7 @@ registerSchema({
43822
44001
  }
43823
44002
  }
43824
44003
  });
43825
- var createCommand3 = defineCommand178({
44004
+ var createCommand3 = defineCommand179({
43826
44005
  meta: {
43827
44006
  name: "create",
43828
44007
  description: 'Stage a scheduled action. Example: baker scheduled-actions create --name "Weekly report" --description "..." --cron "0 9 * * MON"'
@@ -43881,7 +44060,7 @@ var createCommand3 = defineCommand178({
43881
44060
  });
43882
44061
 
43883
44062
  // src/commands/scheduled-actions/delete.ts
43884
- import { defineCommand as defineCommand179 } from "citty";
44063
+ import { defineCommand as defineCommand180 } from "citty";
43885
44064
  registerSchema({
43886
44065
  command: "scheduled-actions.delete",
43887
44066
  description: "Stage deletion of a published scheduled action or cancellation of a temp_sched_* draft creation.",
@@ -43889,7 +44068,7 @@ registerSchema({
43889
44068
  id: { type: "string", description: "Published scheduled action ID or temp_sched_* draft ID", required: true }
43890
44069
  }
43891
44070
  });
43892
- var deleteCommand3 = defineCommand179({
44071
+ var deleteCommand3 = defineCommand180({
43893
44072
  meta: {
43894
44073
  name: "delete",
43895
44074
  description: "Stage scheduled action deletion. Example: baker scheduled-actions delete <id-or-temp_sched_id>"
@@ -43918,7 +44097,7 @@ var deleteCommand3 = defineCommand179({
43918
44097
  });
43919
44098
 
43920
44099
  // src/commands/scheduled-actions/get.ts
43921
- import { defineCommand as defineCommand180 } from "citty";
44100
+ import { defineCommand as defineCommand181 } from "citty";
43922
44101
  registerSchema({
43923
44102
  command: "scheduled-actions.get",
43924
44103
  description: "Get a published scheduled action or a temp_sched_* draft-created scheduled action.",
@@ -43927,7 +44106,7 @@ registerSchema({
43927
44106
  chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
43928
44107
  }
43929
44108
  });
43930
- var getCommand4 = defineCommand180({
44109
+ var getCommand4 = defineCommand181({
43931
44110
  meta: {
43932
44111
  name: "get",
43933
44112
  description: "Get a scheduled action. Example: baker scheduled-actions get <id-or-temp_sched_id>"
@@ -43966,7 +44145,7 @@ var getCommand4 = defineCommand180({
43966
44145
  });
43967
44146
 
43968
44147
  // src/commands/scheduled-actions/list.ts
43969
- import { defineCommand as defineCommand181 } from "citty";
44148
+ import { defineCommand as defineCommand182 } from "citty";
43970
44149
  registerSchema({
43971
44150
  command: "scheduled-actions.list",
43972
44151
  description: "List published scheduled actions. Includes draft state when BAKER_CHAT_ID is set, or --chat <id> to read an earlier chat's staged schedules instead.",
@@ -43974,7 +44153,7 @@ registerSchema({
43974
44153
  chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
43975
44154
  }
43976
44155
  });
43977
- var listCommand15 = defineCommand181({
44156
+ var listCommand15 = defineCommand182({
43978
44157
  meta: {
43979
44158
  name: "list",
43980
44159
  description: "List scheduled actions. Includes staged draft ops when BAKER_CHAT_ID is set, or --chat <id> to read an earlier chat's staged schedules instead."
@@ -43999,7 +44178,7 @@ var listCommand15 = defineCommand181({
43999
44178
  // src/commands/scheduled-actions/templates.ts
44000
44179
  import { readFile as readFile24 } from "fs/promises";
44001
44180
  import path37 from "path";
44002
- import { defineCommand as defineCommand182 } from "citty";
44181
+ import { defineCommand as defineCommand183 } from "citty";
44003
44182
  registerSchema({
44004
44183
  command: "scheduled-actions.templates",
44005
44184
  description: "The recipes available to this company: the ones Baker ships plus the ones they wrote themselves, each with its id, what it produces and how often it is meant to run. Read this before proposing a company's automation, so every recipe you name is one that exists. Also how a company gets a recipe of its own \u2014 save a brief, prove it runs, then publish it.",
@@ -44054,7 +44233,7 @@ registerSchema({
44054
44233
  }
44055
44234
  }
44056
44235
  });
44057
- var templatesCommand = defineCommand182({
44236
+ var templatesCommand = defineCommand183({
44058
44237
  meta: {
44059
44238
  name: "templates",
44060
44239
  description: `The recipes this company can run \u2014 Baker's own plus theirs, with what each one produces.
@@ -44146,7 +44325,7 @@ Full guide: __tooling__/docs/tools/baker/scheduled-actions.md`
44146
44325
  });
44147
44326
 
44148
44327
  // src/commands/scheduled-actions/trigger.ts
44149
- import { defineCommand as defineCommand183 } from "citty";
44328
+ import { defineCommand as defineCommand184 } from "citty";
44150
44329
  registerSchema({
44151
44330
  command: "scheduled-actions.trigger",
44152
44331
  description: "Immediately trigger a published scheduled action. Does not require BAKER_CHAT_ID and rejects temp_sched_* IDs.",
@@ -44154,7 +44333,7 @@ registerSchema({
44154
44333
  id: { type: "string", description: "Published scheduled action ID", required: true }
44155
44334
  }
44156
44335
  });
44157
- var triggerCommand = defineCommand183({
44336
+ var triggerCommand = defineCommand184({
44158
44337
  meta: {
44159
44338
  name: "trigger",
44160
44339
  description: "Immediately trigger a published scheduled action. Example: baker scheduled-actions trigger <id>"
@@ -44191,7 +44370,7 @@ var triggerCommand = defineCommand183({
44191
44370
  });
44192
44371
 
44193
44372
  // src/commands/scheduled-actions/update.ts
44194
- import { defineCommand as defineCommand184 } from "citty";
44373
+ import { defineCommand as defineCommand185 } from "citty";
44195
44374
  registerSchema({
44196
44375
  command: "scheduled-actions.update",
44197
44376
  description: "Stage an update to a published scheduled action or temp_sched_* draft-created scheduled action.",
@@ -44222,7 +44401,7 @@ registerSchema({
44222
44401
  prompt: { type: "string", description: "Replacement additional spawned-agent instructions", required: false }
44223
44402
  }
44224
44403
  });
44225
- var updateCommand3 = defineCommand184({
44404
+ var updateCommand3 = defineCommand185({
44226
44405
  meta: {
44227
44406
  name: "update",
44228
44407
  description: "Stage a scheduled action update. Examples: baker scheduled-actions update <id> --enabled false | baker scheduled-actions update <id> --mode publish"
@@ -44300,7 +44479,7 @@ var updateCommand3 = defineCommand184({
44300
44479
  });
44301
44480
 
44302
44481
  // src/commands/scheduled-actions/index.ts
44303
- var scheduledActionsCommand = defineCommand185({
44482
+ var scheduledActionsCommand = defineCommand186({
44304
44483
  meta: {
44305
44484
  name: "scheduled-actions",
44306
44485
  description: `Manage Scheduled Actions. Subcommands: list, get, create, update, delete, trigger, templates.
@@ -44329,14 +44508,14 @@ Full guide: __tooling__/docs/tools/baker/scheduled-actions.md`
44329
44508
  });
44330
44509
 
44331
44510
  // src/commands/schema.ts
44332
- import { defineCommand as defineCommand186 } from "citty";
44511
+ import { defineCommand as defineCommand187 } from "citty";
44333
44512
  function narrowToFamily(commandName, available) {
44334
44513
  const segments = commandName.split(".");
44335
44514
  const prefix = segments[0] === "ads" && segments[1] ? `ads.${segments[1]}.` : `${segments[0]}.`;
44336
44515
  const siblings = available.filter((name) => name.startsWith(prefix));
44337
44516
  return siblings.length > 0 ? siblings : available;
44338
44517
  }
44339
- var schemaCommand2 = defineCommand186({
44518
+ var schemaCommand2 = defineCommand187({
44340
44519
  meta: {
44341
44520
  name: "schema",
44342
44521
  description: "Inspect command argument schemas (for AI agent introspection). Lists all commands if no argument given. Example: baker schema images.search"
@@ -44380,10 +44559,10 @@ var schemaCommand2 = defineCommand186({
44380
44559
  });
44381
44560
 
44382
44561
  // src/commands/studio/index.ts
44383
- import { defineCommand as defineCommand195 } from "citty";
44562
+ import { defineCommand as defineCommand196 } from "citty";
44384
44563
 
44385
44564
  // src/commands/studio/animate.ts
44386
- import { defineCommand as defineCommand187 } from "citty";
44565
+ import { defineCommand as defineCommand188 } from "citty";
44387
44566
 
44388
44567
  // src/commands/studio/batch.ts
44389
44568
  function projectBatch(generation, full) {
@@ -44834,7 +45013,7 @@ function costHintsFor(body) {
44834
45013
  }
44835
45014
  return hints;
44836
45015
  }
44837
- var animateCommand = defineCommand187({
45016
+ var animateCommand = defineCommand188({
44838
45017
  meta: {
44839
45018
  name: "animate",
44840
45019
  description: "Render a clip. With an image the look is already fixed, so the prompt describes MOVEMENT \u2014 what the camera does, what the subject does, in what order. With --from text there is no image and the prompt is the whole shot.\n\nA rendered clip is NOT usable anywhere until you keep it: `baker studio keep <id> --slot N` is what puts it in the video library. Takes nobody keeps are never ingested, which is what makes a rejected batch cheap.\n\nFor anything longer than 15 seconds, or to build on footage that already exists, use --model bytedance/seedance-2.5: it renders 4-30s and is the only model that reads an existing clip or an existing soundtrack.\n\nExamples:\n baker studio animate 'slow push in, model turns to camera and smiles' --image j57abc123def456ghi789\n baker studio animate 'handheld drift right, steam rising from the cup' --image './out/hero.png' --duration 6 --quality 1080p\n baker studio animate 'product rotates once on a turntable' --image j57abc\u2026,j57def\u2026 --from references\n baker studio animate 'she keeps walking, camera stays with her, then she stops and looks up' --image j57abc\u2026 --from references --from-clip j57batch\u2026:0 --model bytedance/seedance-2.5 --duration 20\n baker studio animate 'hold on the product, then a slow push-in' --from references --from-video j57vid\u2026 --model bytedance/seedance-2.5\n baker studio animate 'slow drone pull-back over a solar farm at golden hour, no people' --from text --model bytedance/seedance-2.5 --duration 12"
@@ -44953,7 +45132,7 @@ var animateCommand = defineCommand187({
44953
45132
  });
44954
45133
 
44955
45134
  // src/commands/studio/generate.ts
44956
- import { defineCommand as defineCommand188 } from "citty";
45135
+ import { defineCommand as defineCommand189 } from "citty";
44957
45136
  var MODEL_LIST2 = IMAGE_MODEL_IDS;
44958
45137
  var DEFAULT_MAX_WAIT_MS2 = 24e4;
44959
45138
  registerSchema({
@@ -45089,7 +45268,7 @@ function buildGenerateBody(args, prompt) {
45089
45268
  }
45090
45269
  return body;
45091
45270
  }
45092
- var generateCommand = defineCommand188({
45271
+ var generateCommand = defineCommand189({
45093
45272
  meta: {
45094
45273
  name: "generate",
45095
45274
  description: "Start here to make an image. Renders 1-8 takes of one brief, ingests each into the media library as it lands, and shows the batch in the dashboard Studio next to the ones the client ran.\n\nModel choice: google/gemini-3.1-flash-image-preview (default \u2014 fast, best at editing a reference and at extreme ratios), google/gemini-3-pro-image-preview (highest fidelity, slower), openai/gpt-image-2 (photoreal and the cleanest in-image text \u2014 no --image-size, no 4:5 / 5:4), recraft/recraft-v4.1-pro-vector (vector/flat marks with palette control).\n\n--reference is the biggest quality lever there is: a real logo, product shot, Pinterest pin or sandbox screenshot beats any amount of adjectives.\n\nExamples:\n baker studio generate 'matte black bottle on wet marble, hard studio light, 35mm' --aspect-ratio 3:2 --count 3\n baker studio generate 'this bottle on a sunlit kitchen counter' --reference './src/brand/product.png,https://\u2026/kitchen.jpg'\n baker studio generate 'founder-style selfie, kitchen background, natural light' --skill ugc-selfie-hook\n baker studio generate 'flat geometric mascot, brand palette' --model recraft/recraft-v4.1-pro-vector --rgb-colors '[[10,10,10],[255,80,0]]'"
@@ -45167,7 +45346,7 @@ var generateCommand = defineCommand188({
45167
45346
  });
45168
45347
 
45169
45348
  // src/commands/studio/get.ts
45170
- import { defineCommand as defineCommand189 } from "citty";
45349
+ import { defineCommand as defineCommand190 } from "citty";
45171
45350
  registerSchema({
45172
45351
  command: "studio.get",
45173
45352
  description: "Read one Studio batch: every take, where it lives, and why a take is missing. This is how you pick up a batch that was still rendering when the start command returned.",
@@ -45176,7 +45355,7 @@ registerSchema({
45176
45355
  full: { type: "boolean", description: "Include settings, references and attribution", required: false }
45177
45356
  }
45178
45357
  });
45179
- var getCommand5 = defineCommand189({
45358
+ var getCommand5 = defineCommand190({
45180
45359
  meta: {
45181
45360
  name: "get",
45182
45361
  description: "Read one Studio batch \u2014 the takes, their urls, whether each is in the library, and the reason for any that failed.\n\nExample: baker studio get j57abc123def456ghi789\nExample: baker studio get j57abc123def456ghi789 --full"
@@ -45205,7 +45384,7 @@ var getCommand5 = defineCommand189({
45205
45384
  });
45206
45385
 
45207
45386
  // src/commands/studio/improve.ts
45208
- import { defineCommand as defineCommand190 } from "citty";
45387
+ import { defineCommand as defineCommand191 } from "citty";
45209
45388
  var DESCRIPTION = "Sharpen a rough brief into directed art direction \u2014 the same rewrite the client gets from the wand in the Studio prompt bar. Reach for it when you are relaying the CLIENT's own words and want them shaped without substituting your voice; when you are writing the art direction yourself, just write it, because you will do a better job than this does.";
45210
45389
  registerSchema({
45211
45390
  command: "studio.improve",
@@ -45230,7 +45409,7 @@ registerSchema({
45230
45409
  }
45231
45410
  }
45232
45411
  });
45233
- var improveCommand = defineCommand190({
45412
+ var improveCommand = defineCommand191({
45234
45413
  meta: {
45235
45414
  name: "improve",
45236
45415
  description: `${DESCRIPTION}
@@ -45274,7 +45453,7 @@ Examples:
45274
45453
  });
45275
45454
 
45276
45455
  // src/commands/studio/keep.ts
45277
- import { defineCommand as defineCommand191 } from "citty";
45456
+ import { defineCommand as defineCommand192 } from "citty";
45278
45457
  registerSchema({
45279
45458
  command: "studio.keep",
45280
45459
  description: "Mark one take as the keeper. For an image this stars it, so the client reviewing the batch sees which one you used. For a CLIP it is the step that puts it in the video library \u2014 until then the clip cannot be used in a canvas, a landing, or an ad.",
@@ -45284,7 +45463,7 @@ registerSchema({
45284
45463
  undo: { type: "boolean", description: "Un-star an image, or take a kept clip back out", required: false }
45285
45464
  }
45286
45465
  });
45287
- var keepCommand = defineCommand191({
45466
+ var keepCommand = defineCommand192({
45288
45467
  meta: {
45289
45468
  name: "keep",
45290
45469
  description: "Mark one take as the keeper. An image gets starred (it was already in the library); a clip gets INGESTED into the video library, which is what makes it usable anywhere else.\n\nExample: baker studio keep j57abc123def456ghi789 --slot 2\nExample: baker studio keep j57abc123def456ghi789 --slot 2 --undo"
@@ -45335,7 +45514,7 @@ var keepCommand = defineCommand191({
45335
45514
  });
45336
45515
 
45337
45516
  // src/commands/studio/list.ts
45338
- import { defineCommand as defineCommand192 } from "citty";
45517
+ import { defineCommand as defineCommand193 } from "citty";
45339
45518
  registerSchema({
45340
45519
  command: "studio.list",
45341
45520
  description: "Recent Studio batches for THIS conversation, newest first \u2014 what you have already generated, so you re-use a take instead of paying for it twice. `--all` widens it to everything the company generated, including what people ran themselves in the dashboard.",
@@ -45346,7 +45525,7 @@ registerSchema({
45346
45525
  full: { type: "boolean", description: "Include settings, references and attribution", required: false }
45347
45526
  }
45348
45527
  });
45349
- var listCommand16 = defineCommand192({
45528
+ var listCommand16 = defineCommand193({
45350
45529
  meta: {
45351
45530
  name: "list",
45352
45531
  description: "Recent Studio batches, newest first. Scoped to this conversation unless you pass --all.\n\nExample: baker studio list\nExample: baker studio list --kind video --limit 5\nExample: baker studio list --all # includes batches the client ran in the dashboard"
@@ -45380,7 +45559,7 @@ var listCommand16 = defineCommand192({
45380
45559
  });
45381
45560
 
45382
45561
  // src/commands/studio/models.ts
45383
- import { defineCommand as defineCommand193 } from "citty";
45562
+ import { defineCommand as defineCommand194 } from "citty";
45384
45563
  var DESCRIPTION2 = "What each Studio model actually accepts: its shapes, resolutions, clip lengths, prompt character cap, how many reference images it takes, and which knobs it has. Read this before a batch you care about \u2014 the models disagree far more than they look like they do, and a setting the chosen model does not have is REFUSED, not ignored.";
45385
45564
  registerSchema({
45386
45565
  command: "studio.models",
@@ -45467,7 +45646,7 @@ function buildModelCards(kind, model) {
45467
45646
  const selected = model ? ids.filter((id) => id === model) : ids;
45468
45647
  return selected.map((id) => build(id));
45469
45648
  }
45470
- var modelsCommand = defineCommand193({
45649
+ var modelsCommand = defineCommand194({
45471
45650
  meta: {
45472
45651
  name: "models",
45473
45652
  description: `${DESCRIPTION2}
@@ -45514,13 +45693,13 @@ Examples:
45514
45693
  });
45515
45694
 
45516
45695
  // src/commands/studio/skills.ts
45517
- import { defineCommand as defineCommand194 } from "citty";
45696
+ import { defineCommand as defineCommand195 } from "citty";
45518
45697
  registerSchema({
45519
45698
  command: "studio.skills",
45520
45699
  description: "The craft directions `studio generate --skill <id>` accepts. Each one carries directed art direction plus the model, shape and take count it wants, so you pick a look by name instead of writing the boilerplate yourself.",
45521
45700
  args: {}
45522
45701
  });
45523
- var skillsCommand = defineCommand194({
45702
+ var skillsCommand = defineCommand195({
45524
45703
  meta: {
45525
45704
  name: "skills",
45526
45705
  description: "List the craft directions available to `baker studio generate --skill <id>` \u2014 what each one is for, whether it wants a reference image, and the model/shape/count it defaults to.\n\nExample: baker studio skills"
@@ -45544,7 +45723,7 @@ var skillsCommand = defineCommand194({
45544
45723
  });
45545
45724
 
45546
45725
  // src/commands/studio/index.ts
45547
- var studioCommand = defineCommand195({
45726
+ var studioCommand = defineCommand196({
45548
45727
  meta: {
45549
45728
  name: "studio",
45550
45729
  description: `Make new imagery and clips. Every batch is recorded and shows up in the dashboard Studio for the client to review, labelled with this conversation.
@@ -45587,10 +45766,10 @@ Full guide: __tooling__/docs/tools/baker/studio.md`
45587
45766
  });
45588
45767
 
45589
45768
  // src/commands/tag-manager/index.ts
45590
- import { defineCommand as defineCommand199 } from "citty";
45769
+ import { defineCommand as defineCommand200 } from "citty";
45591
45770
 
45592
45771
  // src/commands/tag-manager/draft.ts
45593
- import { defineCommand as defineCommand196 } from "citty";
45772
+ import { defineCommand as defineCommand197 } from "citty";
45594
45773
 
45595
45774
  // src/commands/tag-manager/shared.ts
45596
45775
  import { readFileSync as readFileSync15 } from "fs";
@@ -45713,13 +45892,13 @@ registerSchema({
45713
45892
  chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
45714
45893
  }
45715
45894
  });
45716
- var draftCommand4 = defineCommand196({
45895
+ var draftCommand4 = defineCommand197({
45717
45896
  meta: {
45718
45897
  name: "draft",
45719
45898
  description: "List, show, amend, remove, or clear staged Tag Manager changes for this chat. `list` and `show` take --chat <id> to read an earlier chat's changes instead."
45720
45899
  },
45721
45900
  subCommands: {
45722
- list: defineCommand196({
45901
+ list: defineCommand197({
45723
45902
  meta: {
45724
45903
  name: "list",
45725
45904
  description: "Review everything staged on this chat (--json for the raw envelope)"
@@ -45732,7 +45911,7 @@ var draftCommand4 = defineCommand196({
45732
45911
  await draftList2(args.json === true, args.chat);
45733
45912
  }
45734
45913
  }),
45735
- show: defineCommand196({
45914
+ show: defineCommand197({
45736
45915
  meta: {
45737
45916
  name: "show",
45738
45917
  description: "Print the full staged payload for one change \u2014 the receipt to verify it looks right before publish (never truncated)."
@@ -45749,7 +45928,7 @@ var draftCommand4 = defineCommand196({
45749
45928
  );
45750
45929
  }
45751
45930
  }),
45752
- amend: defineCommand196({
45931
+ amend: defineCommand197({
45753
45932
  meta: {
45754
45933
  name: "amend",
45755
45934
  description: "Update a staged change in place \u2014 merges a JSON patch into its payload (objects deep-merge, null deletes a key, arrays/scalars replace) and re-validates. Use this instead of remove + re-create."
@@ -45766,7 +45945,7 @@ var draftCommand4 = defineCommand196({
45766
45945
  });
45767
45946
  }
45768
45947
  }),
45769
- remove: defineCommand196({
45948
+ remove: defineCommand197({
45770
45949
  meta: { name: "remove", description: "Remove one staged change (cascades to anything depending on it)" },
45771
45950
  args: { ref: { type: "positional", description: "Staged ref (gtm_temp_*) or target", required: false } },
45772
45951
  run: async ({ args }) => {
@@ -45775,7 +45954,7 @@ var draftCommand4 = defineCommand196({
45775
45954
  });
45776
45955
  }
45777
45956
  }),
45778
- clear: defineCommand196({
45957
+ clear: defineCommand197({
45779
45958
  meta: { name: "clear", description: "Discard all Tag Manager changes staged on this chat" },
45780
45959
  run: async () => {
45781
45960
  await draftAction3("/api/tag-manager/draft/clear", {});
@@ -45785,7 +45964,7 @@ var draftCommand4 = defineCommand196({
45785
45964
  });
45786
45965
 
45787
45966
  // src/commands/tag-manager/read.ts
45788
- import { defineCommand as defineCommand197 } from "citty";
45967
+ import { defineCommand as defineCommand198 } from "citty";
45789
45968
  registerSchema({
45790
45969
  command: "tagManager.containers",
45791
45970
  description: "List the Google Tag Manager containers this company's connection can reach. Every container the company connected is flagged `connected: true` \u2014 there can be several, and Baker may read and change all of them. Start here to confirm which containers you are managing.",
@@ -45826,7 +46005,7 @@ function containersHints(containers) {
45826
46005
  }))
45827
46006
  });
45828
46007
  }
45829
- var containersCommand = defineCommand197({
46008
+ var containersCommand = defineCommand198({
45830
46009
  meta: {
45831
46010
  name: "containers",
45832
46011
  description: `List Tag Manager containers reachable by this company's connection.
@@ -45843,7 +46022,7 @@ Start here:
45843
46022
  }
45844
46023
  }
45845
46024
  });
45846
- var readCommand = defineCommand197({
46025
+ var readCommand = defineCommand198({
45847
46026
  meta: {
45848
46027
  name: "read",
45849
46028
  description: `Read the current contents of the Tag Manager container \u2014 always do this before staging changes.
@@ -45885,7 +46064,7 @@ Examples:
45885
46064
  });
45886
46065
 
45887
46066
  // src/commands/tag-manager/write-commands.ts
45888
- import { defineCommand as defineCommand198 } from "citty";
46067
+ import { defineCommand as defineCommand199 } from "citty";
45889
46068
  var CONTAINER_ARG_DESCRIPTION = "Numeric container id (optional only when one container is connected \u2014 run `baker tag-manager containers`)";
45890
46069
  var ENTITIES = [
45891
46070
  {
@@ -45941,10 +46120,10 @@ for (const { entity, noun, createHint } of ENTITIES) {
45941
46120
  });
45942
46121
  }
45943
46122
  function entityCommand(entity, noun, example) {
45944
- return defineCommand198({
46123
+ return defineCommand199({
45945
46124
  meta: { name: entity, description: `Stage ${noun} changes on this chat's Tag Manager draft` },
45946
46125
  subCommands: {
45947
- create: defineCommand198({
46126
+ create: defineCommand199({
45948
46127
  meta: {
45949
46128
  name: "create",
45950
46129
  description: `Stage a new ${noun}
@@ -45966,7 +46145,7 @@ Examples:
45966
46145
  });
45967
46146
  }
45968
46147
  }),
45969
- update: defineCommand198({
46148
+ update: defineCommand199({
45970
46149
  meta: {
45971
46150
  name: "update",
45972
46151
  description: `Stage an update to an existing ${noun} (pass its id or path)`
@@ -45986,7 +46165,7 @@ Examples:
45986
46165
  });
45987
46166
  }
45988
46167
  }),
45989
- delete: defineCommand198({
46168
+ delete: defineCommand199({
45990
46169
  meta: { name: "delete", description: `Stage the deletion of a ${noun} (pass its id or path)` },
45991
46170
  args: {
45992
46171
  id: { type: "positional", description: `${noun} id or path`, required: false },
@@ -46027,7 +46206,7 @@ function builtinTypes(args) {
46027
46206
  }
46028
46207
  return raw.split(",").map((entry) => entry.trim());
46029
46208
  }
46030
- var builtinCommand = defineCommand198({
46209
+ var builtinCommand = defineCommand199({
46031
46210
  meta: {
46032
46211
  name: "builtin",
46033
46212
  description: `Enable or disable built-in variables
@@ -46037,7 +46216,7 @@ Examples:
46037
46216
  baker tag-manager builtin disable --types formId`
46038
46217
  },
46039
46218
  subCommands: {
46040
- enable: defineCommand198({
46219
+ enable: defineCommand199({
46041
46220
  meta: { name: "enable", description: "Stage enabling built-in variables" },
46042
46221
  args: {
46043
46222
  types: { type: "string", description: "Comma-separated types", required: false },
@@ -46051,7 +46230,7 @@ Examples:
46051
46230
  });
46052
46231
  }
46053
46232
  }),
46054
- disable: defineCommand198({
46233
+ disable: defineCommand199({
46055
46234
  meta: { name: "disable", description: "Stage disabling built-in variables" },
46056
46235
  args: {
46057
46236
  types: { type: "string", description: "Comma-separated types", required: false },
@@ -46069,7 +46248,7 @@ Examples:
46069
46248
  });
46070
46249
 
46071
46250
  // src/commands/tag-manager/index.ts
46072
- var tagManagerCommand = defineCommand199({
46251
+ var tagManagerCommand = defineCommand200({
46073
46252
  meta: {
46074
46253
  name: "tag-manager",
46075
46254
  description: `Read and change what lives inside the client's Google Tag Manager container \u2014 tags, triggers, variables, folders and built-in variables.
@@ -46106,7 +46285,7 @@ Full guide: __tooling__/docs/tools/baker/tag-manager.md`
46106
46285
  });
46107
46286
 
46108
46287
  // src/commands/tags/index.ts
46109
- import { defineCommand as defineCommand200 } from "citty";
46288
+ import { defineCommand as defineCommand201 } from "citty";
46110
46289
 
46111
46290
  // src/commands/tags/shared.ts
46112
46291
  function failApi3(err) {
@@ -46175,7 +46354,7 @@ async function listTags(json) {
46175
46354
  var listArgs9 = {
46176
46355
  json: { type: "boolean", description: "Print the raw JSON envelope instead of the readable list" }
46177
46356
  };
46178
- var listCommand17 = defineCommand200({
46357
+ var listCommand17 = defineCommand201({
46179
46358
  meta: {
46180
46359
  name: "list",
46181
46360
  description: "Effective tags for this chat (production + staged), with each tag's full readable config (secrets excluded) \u2014 reuse a stored value to pre-fill a change rather than asking the user. Refs printed here are what flow side-effect tagIds should use. Example: baker tags list"
@@ -46194,7 +46373,7 @@ async function listDraft3(chat) {
46194
46373
  failApi3(err);
46195
46374
  }
46196
46375
  }
46197
- var draftCommand5 = defineCommand200({
46376
+ var draftCommand5 = defineCommand201({
46198
46377
  meta: {
46199
46378
  name: "draft",
46200
46379
  description: "Review the tag changes staged in this chat (read-only). Staged changes were approved via request_tag_input and apply when the chat is published; to amend or drop one, propose a follow-up change through the same tool (a delete on a tag_temp_* ref drops the staged create). Takes --chat <id> to read an earlier chat's staged changes instead."
@@ -46204,7 +46383,7 @@ var draftCommand5 = defineCommand200({
46204
46383
  await listDraft3(args.chat);
46205
46384
  }
46206
46385
  });
46207
- var tagsCommand3 = defineCommand200({
46386
+ var tagsCommand3 = defineCommand201({
46208
46387
  meta: {
46209
46388
  name: "tags",
46210
46389
  description: `Read the client's marketing/analytics tags (Meta pixel, GA4, Google Ads, GTM, Clarity, Hotjar, \u2026) \u2014 production tags plus the changes staged in this chat.
@@ -46233,10 +46412,10 @@ Full guide: __tooling__/docs/tools/baker/tags.md`
46233
46412
  });
46234
46413
 
46235
46414
  // src/commands/testimonials/index.ts
46236
- import { defineCommand as defineCommand204 } from "citty";
46415
+ import { defineCommand as defineCommand205 } from "citty";
46237
46416
 
46238
46417
  // src/commands/testimonials/get.ts
46239
- import { defineCommand as defineCommand201 } from "citty";
46418
+ import { defineCommand as defineCommand202 } from "citty";
46240
46419
  registerSchema({
46241
46420
  command: "testimonials.get",
46242
46421
  description: "Get a single testimonial by ID",
@@ -46244,7 +46423,7 @@ registerSchema({
46244
46423
  id: { type: "string", description: "Testimonial ID", required: true }
46245
46424
  }
46246
46425
  });
46247
- var getCommand6 = defineCommand201({
46426
+ var getCommand6 = defineCommand202({
46248
46427
  meta: { name: "get", description: "Get a single testimonial by ID. Example: baker testimonials get j571abc123" },
46249
46428
  args: {
46250
46429
  id: { type: "positional", description: "Testimonial ID", required: false },
@@ -46281,7 +46460,7 @@ var getCommand6 = defineCommand201({
46281
46460
  });
46282
46461
 
46283
46462
  // src/commands/testimonials/list.ts
46284
- import { defineCommand as defineCommand202 } from "citty";
46463
+ import { defineCommand as defineCommand203 } from "citty";
46285
46464
 
46286
46465
  // src/commands/testimonials/emptyCorpusHints.ts
46287
46466
  function resolveEmptyReason({
@@ -46416,7 +46595,7 @@ function buildListParams(args) {
46416
46595
  }
46417
46596
  return params;
46418
46597
  }
46419
- var listCommand18 = defineCommand202({
46598
+ var listCommand18 = defineCommand203({
46420
46599
  meta: {
46421
46600
  name: "list",
46422
46601
  description: "List testimonials with optional filters. Example: baker testimonials list --source google --sentiment positive"
@@ -46468,7 +46647,7 @@ var listCommand18 = defineCommand202({
46468
46647
  });
46469
46648
 
46470
46649
  // src/commands/testimonials/search.ts
46471
- import { defineCommand as defineCommand203 } from "citty";
46650
+ import { defineCommand as defineCommand204 } from "citty";
46472
46651
  var FILTER_FLAGS2 = ["source", "rating-min", "rating-max", "status", "sentiment", "language", "tags"];
46473
46652
  function languageBiasHint(results, requestedLanguage) {
46474
46653
  if (requestedLanguage) {
@@ -46547,7 +46726,7 @@ function buildSearchRequest(query, args) {
46547
46726
  }
46548
46727
  return body;
46549
46728
  }
46550
- var searchCommand3 = defineCommand203({
46729
+ var searchCommand3 = defineCommand204({
46551
46730
  meta: {
46552
46731
  name: "search",
46553
46732
  description: "Semantic search testimonials by text query. Uses hybrid BM25 + vector + reranking. Example: baker testimonials search 'great service' --rating-min 4"
@@ -46611,7 +46790,7 @@ var searchCommand3 = defineCommand203({
46611
46790
  var tagsCommand4 = makeTagsCommand("testimonials", "testimonial", "/api/testimonials/tags");
46612
46791
 
46613
46792
  // src/commands/testimonials/index.ts
46614
- var testimonialsCommand = defineCommand204({
46793
+ var testimonialsCommand = defineCommand205({
46615
46794
  meta: {
46616
46795
  name: "testimonials",
46617
46796
  description: `Find and browse testimonials in Baker. Subcommands: search, get, list, tags.
@@ -46633,10 +46812,10 @@ Full guide: __tooling__/docs/tools/baker/testimonials.md`
46633
46812
  });
46634
46813
 
46635
46814
  // src/commands/videos/index.ts
46636
- import { defineCommand as defineCommand211 } from "citty";
46815
+ import { defineCommand as defineCommand212 } from "citty";
46637
46816
 
46638
46817
  // src/commands/videos/delete.ts
46639
- import { defineCommand as defineCommand205 } from "citty";
46818
+ import { defineCommand as defineCommand206 } from "citty";
46640
46819
  registerSchema({
46641
46820
  command: "videos.delete",
46642
46821
  description: "Delete a video by ID",
@@ -46650,7 +46829,7 @@ registerSchema({
46650
46829
  }
46651
46830
  }
46652
46831
  });
46653
- var deleteCommand4 = defineCommand205({
46832
+ var deleteCommand4 = defineCommand206({
46654
46833
  meta: {
46655
46834
  name: "delete",
46656
46835
  description: "Delete a video by ID. Use --dry-run to preview. Example: baker videos delete j571abc123 --dry-run"
@@ -46691,7 +46870,7 @@ var deleteCommand4 = defineCommand205({
46691
46870
  });
46692
46871
 
46693
46872
  // src/commands/videos/get.ts
46694
- import { defineCommand as defineCommand206 } from "citty";
46873
+ import { defineCommand as defineCommand207 } from "citty";
46695
46874
  registerSchema({
46696
46875
  command: "videos.get",
46697
46876
  description: "Get a single video by ID",
@@ -46699,7 +46878,7 @@ registerSchema({
46699
46878
  id: { type: "string", description: "Video ID", required: true }
46700
46879
  }
46701
46880
  });
46702
- var getCommand7 = defineCommand206({
46881
+ var getCommand7 = defineCommand207({
46703
46882
  meta: { name: "get", description: "Get a single video by ID. Example: baker videos get j571abc123" },
46704
46883
  args: {
46705
46884
  id: { type: "positional", description: "Video ID", required: false },
@@ -46736,7 +46915,7 @@ var getCommand7 = defineCommand206({
46736
46915
  });
46737
46916
 
46738
46917
  // src/commands/videos/group.ts
46739
- import { defineCommand as defineCommand207 } from "citty";
46918
+ import { defineCommand as defineCommand208 } from "citty";
46740
46919
  registerSchema({
46741
46920
  command: "videos.group",
46742
46921
  description: "List every clip and image that arrived in the same set as this video (carousel slides, one page)",
@@ -46745,7 +46924,7 @@ registerSchema({
46745
46924
  "group-key": { type: "string", description: "The set key directly, when you already have it", required: false }
46746
46925
  }
46747
46926
  });
46748
- var groupCommand2 = defineCommand207({
46927
+ var groupCommand2 = defineCommand208({
46749
46928
  meta: {
46750
46929
  name: "group",
46751
46930
  description: "List every asset that arrived in the same set as this clip \u2014 the other slides of the Instagram post it came from, stills included. A carousel is authored to be read in order, so a clip pulled out of one is usually missing half its meaning. Example: baker videos group <videoId>"
@@ -46768,7 +46947,7 @@ var groupCommand2 = defineCommand207({
46768
46947
  import { mkdtemp as mkdtemp2, rm as rm7, stat as stat7 } from "fs/promises";
46769
46948
  import { tmpdir as tmpdir3 } from "os";
46770
46949
  import path38 from "path";
46771
- import { defineCommand as defineCommand208 } from "citty";
46950
+ import { defineCommand as defineCommand209 } from "citty";
46772
46951
 
46773
46952
  // src/lib/streamUpload.ts
46774
46953
  import { createHash as createHash2 } from "crypto";
@@ -46932,7 +47111,7 @@ registerSchema({
46932
47111
  "dry-run": { type: "boolean", description: "Preview the operation without executing", required: false }
46933
47112
  }
46934
47113
  });
46935
- var ingestCommand2 = defineCommand208({
47114
+ var ingestCommand2 = defineCommand209({
46936
47115
  meta: {
46937
47116
  name: "ingest",
46938
47117
  description: "Add a video to the library from a URL. A direct file URL is handed straight to Baker, which fetches it. A page URL (YouTube, TikTok, Vimeo, Instagram) is downloaded here first, then uploaded \u2014 and a direct URL that Baker cannot fetch falls back to that same path automatically.\n\nExample: baker videos ingest https://www.youtube.com/watch?v=abc123"
@@ -47194,7 +47373,7 @@ async function uploadToAssetStore(filePath, sizeBytes) {
47194
47373
  }
47195
47374
 
47196
47375
  // src/commands/videos/search.ts
47197
- import { defineCommand as defineCommand209 } from "citty";
47376
+ import { defineCommand as defineCommand210 } from "citty";
47198
47377
  registerSchema({
47199
47378
  command: "videos.search",
47200
47379
  description: "Search videos by text query. Only returns ready videos.",
@@ -47204,7 +47383,7 @@ registerSchema({
47204
47383
  tags: { type: "string", description: "Comma-separated tags to filter by", required: false }
47205
47384
  }
47206
47385
  });
47207
- var searchCommand4 = defineCommand209({
47386
+ var searchCommand4 = defineCommand210({
47208
47387
  meta: {
47209
47388
  name: "search",
47210
47389
  description: "Semantic search videos by text query. Uses hybrid BM25 + vector + reranking. Example: baker videos search 'product demo' --tags tutorial"
@@ -47256,7 +47435,7 @@ var tagsCommand5 = makeTagsCommand("videos", "video", "/api/videos/tags");
47256
47435
  // src/commands/videos/upload.ts
47257
47436
  import { readFile as readFile25, stat as stat8 } from "fs/promises";
47258
47437
  import { basename as basename3, extname as extname4 } from "path";
47259
- import { defineCommand as defineCommand210 } from "citty";
47438
+ import { defineCommand as defineCommand211 } from "citty";
47260
47439
  var MIME_MAP = {
47261
47440
  ".mp4": "video/mp4",
47262
47441
  ".mov": "video/quicktime",
@@ -47298,7 +47477,7 @@ function detectContentType(filePath) {
47298
47477
  function isRemoteUrl3(value) {
47299
47478
  return /^https?:\/\//i.test(value);
47300
47479
  }
47301
- var uploadCommand2 = defineCommand210({
47480
+ var uploadCommand2 = defineCommand211({
47302
47481
  meta: {
47303
47482
  name: "upload",
47304
47483
  description: "Upload a video to Baker \u2014 accepts a local file path OR a remote http(s) URL.\n\nLocal: auto-detects content type and uploads via Mux direct upload.\nRemote: hands off to `videos ingest` (direct fetch, or download-then-upload for a YouTube/TikTok/Vimeo page).\n\nExamples:\n baker videos upload ./demo.mp4\n baker videos upload https://www.youtube.com/watch?v=abc123"
@@ -47382,7 +47561,7 @@ var uploadCommand2 = defineCommand210({
47382
47561
  });
47383
47562
 
47384
47563
  // src/commands/videos/index.ts
47385
- var videosCommand = defineCommand211({
47564
+ var videosCommand = defineCommand212({
47386
47565
  meta: {
47387
47566
  name: "videos",
47388
47567
  description: `Find and manage videos in Baker. Subcommands: search, get, upload, ingest, delete, tags.
@@ -47409,10 +47588,10 @@ Full guide: __tooling__/docs/tools/baker/videos.md`
47409
47588
  });
47410
47589
 
47411
47590
  // src/commands/winning-ads/index.ts
47412
- import { defineCommand as defineCommand224 } from "citty";
47591
+ import { defineCommand as defineCommand225 } from "citty";
47413
47592
 
47414
47593
  // src/commands/winning-ads/advertisers.ts
47415
- import { defineCommand as defineCommand212 } from "citty";
47594
+ import { defineCommand as defineCommand213 } from "citty";
47416
47595
 
47417
47596
  // src/commands/winning-ads/shared.ts
47418
47597
  function splitList2(value) {
@@ -47465,7 +47644,7 @@ function advertiserNormalizer(record, full) {
47465
47644
  last_synced_at: record.last_synced_at ?? null
47466
47645
  };
47467
47646
  }
47468
- var advertisersCommand2 = defineCommand212({
47647
+ var advertisersCommand2 = defineCommand213({
47469
47648
  meta: {
47470
47649
  name: "advertisers",
47471
47650
  description: 'List corpus advertisers by name or domain. Find your own advertiser for --exclude-advertiser, or a competitor for --advertiser-id / winners. Example: baker winning-ads advertisers "Deel" --output md'
@@ -47523,7 +47702,7 @@ var advertisersCommand2 = defineCommand212({
47523
47702
  });
47524
47703
 
47525
47704
  // src/commands/winning-ads/brief.ts
47526
- import { defineCommand as defineCommand213 } from "citty";
47705
+ import { defineCommand as defineCommand214 } from "citty";
47527
47706
  registerSchema({
47528
47707
  command: "winning-ads.brief",
47529
47708
  description: "Generate a creative brief grounded in strategically-similar winning ads. Optionally describe the target creative with --dna (JSON) and steer with --notes.",
@@ -47569,7 +47748,7 @@ function parseDna(raw) {
47569
47748
  }
47570
47749
  return parsed;
47571
47750
  }
47572
- var briefCommand = defineCommand213({
47751
+ var briefCommand = defineCommand214({
47573
47752
  meta: {
47574
47753
  name: "brief",
47575
47754
  description: `Generate a creative brief from winning references. Example: baker winning-ads brief --dna '{"angle":"cost savings"}' --notes "B2B, LinkedIn video" --k 8`
@@ -47605,7 +47784,7 @@ var briefCommand = defineCommand213({
47605
47784
  });
47606
47785
 
47607
47786
  // src/commands/winning-ads/content.ts
47608
- import { defineCommand as defineCommand214 } from "citty";
47787
+ import { defineCommand as defineCommand215 } from "citty";
47609
47788
  registerSchema({
47610
47789
  command: "winning-ads.content",
47611
47790
  description: "Read what's INSIDE one winning ad: the spoken transcript, the on-screen text, and the ad copy. Use this after `search`/`winners`/`feed` return a shortlist \u2014 pass an ad_id to understand a reference before reproducing it. Add --full for speech, pacing, and soundtrack detail. Video ads carry the transcript/on-screen text; static ads carry only the copy.",
@@ -47618,7 +47797,7 @@ registerSchema({
47618
47797
  }
47619
47798
  }
47620
47799
  });
47621
- var contentCommand = defineCommand214({
47800
+ var contentCommand = defineCommand215({
47622
47801
  meta: {
47623
47802
  name: "content",
47624
47803
  description: "Read the transcript + on-screen text + copy of one winning ad. Example: baker winning-ads content adg_123 --platform meta --full --output md"
@@ -47667,7 +47846,7 @@ var contentCommand = defineCommand214({
47667
47846
  });
47668
47847
 
47669
47848
  // src/commands/winning-ads/feed.ts
47670
- import { defineCommand as defineCommand215 } from "citty";
47849
+ import { defineCommand as defineCommand216 } from "citty";
47671
47850
  function buildFeedParams(input) {
47672
47851
  const params = {};
47673
47852
  const advertiser = splitList2(input.advertiser);
@@ -47719,7 +47898,7 @@ registerSchema({
47719
47898
  format: { type: "string", description: "Comma-separated formats to include (e.g. static,video)", required: false }
47720
47899
  }
47721
47900
  });
47722
- var feedCommand = defineCommand215({
47901
+ var feedCommand = defineCommand216({
47723
47902
  meta: {
47724
47903
  name: "feed",
47725
47904
  description: "Winners across every brand you follow (browse, then trim per advertiser). Example: baker winning-ads feed --per-advertiser 5 --output md"
@@ -47804,7 +47983,7 @@ var feedCommand = defineCommand215({
47804
47983
  });
47805
47984
 
47806
47985
  // src/commands/winning-ads/follow.ts
47807
- import { defineCommand as defineCommand216 } from "citty";
47986
+ import { defineCommand as defineCommand217 } from "citty";
47808
47987
  var PLATFORMS = ["meta", "linkedin"];
47809
47988
  registerSchema({
47810
47989
  command: "winning-ads.follow",
@@ -47819,7 +47998,7 @@ registerSchema({
47819
47998
  label: { type: "string", description: "Optional display label (defaults to the resolved name)", required: false }
47820
47999
  }
47821
48000
  });
47822
- var followCommand = defineCommand216({
48001
+ var followCommand = defineCommand217({
47823
48002
  meta: {
47824
48003
  name: "follow",
47825
48004
  description: 'Follow a brand to track ALL its ads \u2014 every platform and country. --platform is how we read your input, not a limit. A domain tracks both Meta + LinkedIn. Example: baker winning-ads follow "deel.com" --platform meta'
@@ -47866,7 +48045,7 @@ var followCommand = defineCommand216({
47866
48045
  });
47867
48046
 
47868
48047
  // src/commands/winning-ads/follow-competitors.ts
47869
- import { defineCommand as defineCommand217 } from "citty";
48048
+ import { defineCommand as defineCommand218 } from "citty";
47870
48049
  var PLATFORMS2 = ["meta", "linkedin"];
47871
48050
  var BATCH_TIMEOUT_MS = 3e5;
47872
48051
  function buildFollowBatchBody(input) {
@@ -47899,7 +48078,7 @@ registerSchema({
47899
48078
  }
47900
48079
  }
47901
48080
  });
47902
- var followCompetitorsCommand = defineCommand217({
48081
+ var followCompetitorsCommand = defineCommand218({
47903
48082
  meta: {
47904
48083
  name: "follow-competitors",
47905
48084
  description: 'Follow many brands at once by domain \u2014 add every competitor in one call. Example: baker winning-ads follow-competitors "deel.com,notion.so,hubspot.com"'
@@ -47974,7 +48153,7 @@ var followCompetitorsCommand = defineCommand217({
47974
48153
  });
47975
48154
 
47976
48155
  // src/commands/winning-ads/following.ts
47977
- import { defineCommand as defineCommand218 } from "citty";
48156
+ import { defineCommand as defineCommand219 } from "citty";
47978
48157
  registerSchema({
47979
48158
  command: "winning-ads.following",
47980
48159
  description: "List the brands you follow in your ad-dna library, with each one's status (ready vs still adding) and cached ad counts. A brand still adding has counts that are a lie in progress; one with `discovery_failed` has counts that are short because we couldn't finish looking, which is not the same as it running no ads.",
@@ -48028,7 +48207,7 @@ function followingNormalizer(record, full) {
48028
48207
  platforms: Array.isArray(record.platforms) ? record.platforms : []
48029
48208
  };
48030
48209
  }
48031
- var followingCommand = defineCommand218({
48210
+ var followingCommand = defineCommand219({
48032
48211
  meta: {
48033
48212
  name: "following",
48034
48213
  description: "List brands you follow, with status (ready / adding\u2026) and cached counts. A brand's counts are only final once it is ready. Example: baker winning-ads following --output md"
@@ -48064,7 +48243,7 @@ var followingCommand = defineCommand218({
48064
48243
  });
48065
48244
 
48066
48245
  // src/commands/winning-ads/patterns.ts
48067
- import { defineCommand as defineCommand219 } from "citty";
48246
+ import { defineCommand as defineCommand220 } from "citty";
48068
48247
  registerSchema({
48069
48248
  command: "winning-ads.patterns",
48070
48249
  description: "Mine what separates two cohorts of ads: pass a comma-list of winning ad ids (--winners) and a comma-list of weaker ad ids (--duds). Returns the discriminating DNA fields.",
@@ -48103,7 +48282,7 @@ function discriminatorRow(record) {
48103
48282
  top_values_duds: Array.isArray(record.top_values_b) ? record.top_values_b.join(", ") : ""
48104
48283
  };
48105
48284
  }
48106
- var patternsCommand = defineCommand219({
48285
+ var patternsCommand = defineCommand220({
48107
48286
  meta: {
48108
48287
  name: "patterns",
48109
48288
  description: "Discover what separates winning ads from weak ones. Example: baker winning-ads patterns --winners a_1,a_2,a_3 --duds a_9,a_8 --output md"
@@ -48159,7 +48338,7 @@ var patternsCommand = defineCommand219({
48159
48338
  });
48160
48339
 
48161
48340
  // src/commands/winning-ads/search.ts
48162
- import { defineCommand as defineCommand220 } from "citty";
48341
+ import { defineCommand as defineCommand221 } from "citty";
48163
48342
  registerSchema({
48164
48343
  command: "winning-ads.search",
48165
48344
  description: "Search the ad-dna corpus of scored winning ads. Returns a lean shortlist (advertiser, summary, scores, media_url) to pick a reference to reproduce.",
@@ -48267,7 +48446,7 @@ function buildSearchBody2(args) {
48267
48446
  }
48268
48447
  return body;
48269
48448
  }
48270
- var searchCommand5 = defineCommand220({
48449
+ var searchCommand5 = defineCommand221({
48271
48450
  meta: {
48272
48451
  name: "search",
48273
48452
  description: "Search winning reference ads. Example: baker winning-ads search 'B2B SaaS before/after AI automation' --platform meta --format static --winner-category winner --exclude-advertiser adv_123 --output md"
@@ -48382,7 +48561,7 @@ var searchCommand5 = defineCommand220({
48382
48561
  });
48383
48562
 
48384
48563
  // src/commands/winning-ads/seeds.ts
48385
- import { defineCommand as defineCommand221 } from "citty";
48564
+ import { defineCommand as defineCommand222 } from "citty";
48386
48565
  function leanRow(r) {
48387
48566
  return {
48388
48567
  key: r.key,
@@ -48410,7 +48589,7 @@ function makeSeedCommand(opts) {
48410
48589
  limit: { type: "number", description: "Max keys 1-100 (default 20)", required: false, default: 20 }
48411
48590
  }
48412
48591
  });
48413
- return defineCommand221({
48592
+ return defineCommand222({
48414
48593
  meta: { name: opts.name, description: opts.description },
48415
48594
  args: {
48416
48595
  platform: { type: "string", description: "Single platform to segment on", required: false },
@@ -48459,7 +48638,7 @@ var formatsCommand = makeSeedCommand({
48459
48638
  });
48460
48639
 
48461
48640
  // src/commands/winning-ads/unfollow.ts
48462
- import { defineCommand as defineCommand222 } from "citty";
48641
+ import { defineCommand as defineCommand223 } from "citty";
48463
48642
  registerSchema({
48464
48643
  command: "winning-ads.unfollow",
48465
48644
  description: "Stop following a brand \u2014 removes it from your ad-dna library by advertiser id.",
@@ -48467,7 +48646,7 @@ registerSchema({
48467
48646
  advertiser: { type: "string", description: "Advertiser id to unfollow", required: true }
48468
48647
  }
48469
48648
  });
48470
- var unfollowCommand = defineCommand222({
48649
+ var unfollowCommand = defineCommand223({
48471
48650
  meta: {
48472
48651
  name: "unfollow",
48473
48652
  description: "Stop following a brand by advertiser id. Example: baker winning-ads unfollow adv_123"
@@ -48488,7 +48667,7 @@ var unfollowCommand = defineCommand222({
48488
48667
  });
48489
48668
 
48490
48669
  // src/commands/winning-ads/winners.ts
48491
- import { defineCommand as defineCommand223 } from "citty";
48670
+ import { defineCommand as defineCommand224 } from "citty";
48492
48671
  registerSchema({
48493
48672
  command: "winning-ads.winners",
48494
48673
  description: "Top winning ads for one advertiser id (from `advertisers` or `following`). Returns lean winner cards; add --full for DNA + longevity.",
@@ -48498,7 +48677,7 @@ registerSchema({
48498
48677
  platform: { type: "string", description: "Filter to a single platform: meta|linkedin", required: false }
48499
48678
  }
48500
48679
  });
48501
- var winnersCommand = defineCommand223({
48680
+ var winnersCommand = defineCommand224({
48502
48681
  meta: {
48503
48682
  name: "winners",
48504
48683
  description: "Top winning ads for a specific advertiser id. Example: baker winning-ads winners adv_123 --top 15 --output md"
@@ -48548,7 +48727,7 @@ var winnersCommand = defineCommand223({
48548
48727
  });
48549
48728
 
48550
48729
  // src/commands/winning-ads/index.ts
48551
- var winningAdsCommand = defineCommand224({
48730
+ var winningAdsCommand = defineCommand225({
48552
48731
  meta: {
48553
48732
  name: "winning-ads",
48554
48733
  description: `Search the ad-dna corpus of scored "winning" ads for reference creatives to reproduce, and manage the brands your library tracks. Proxied through the Baker backend (BAKER_API_KEY) \u2014 no separate token needed.
@@ -48786,7 +48965,7 @@ function getCliVersion() {
48786
48965
  }
48787
48966
 
48788
48967
  // src/cli.ts
48789
- var main = defineCommand225({
48968
+ var main = defineCommand226({
48790
48969
  meta: {
48791
48970
  name: "baker",
48792
48971
  version: getCliVersion(),