@koda-sl/baker-cli 0.225.0 → 0.228.0-dev.7fac4f17c
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +48 -0
- package/dist/{chunk-EKLAHWSF.js → chunk-CMPAHYLB.js} +4 -4
- package/dist/chunk-CMPAHYLB.js.map +1 -0
- package/dist/cli.js +888 -367
- package/dist/cli.js.map +1 -1
- package/dist/engine/index.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-EKLAHWSF.js.map +0 -1
package/dist/cli.js
CHANGED
|
@@ -58,7 +58,7 @@ import {
|
|
|
58
58
|
ulid,
|
|
59
59
|
validateCanvasDeep,
|
|
60
60
|
ytDlpBlockSignal
|
|
61
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-CMPAHYLB.js";
|
|
62
62
|
import {
|
|
63
63
|
csvOrJson,
|
|
64
64
|
daysAgoIso,
|
|
@@ -108,7 +108,7 @@ import {
|
|
|
108
108
|
} from "./chunk-DZUVUGEP.js";
|
|
109
109
|
|
|
110
110
|
// src/cli.ts
|
|
111
|
-
import { defineCommand as
|
|
111
|
+
import { defineCommand as defineCommand222, runMain } from "citty";
|
|
112
112
|
|
|
113
113
|
// src/cache-flag.ts
|
|
114
114
|
var NO_CACHE_ARG = {
|
|
@@ -4432,6 +4432,10 @@ var chatChangeTypeSchema = z10.enum([
|
|
|
4432
4432
|
// One Studio batch — the takes of one brief, as a set. See convex/lib/validators.ts.
|
|
4433
4433
|
"studio-generation",
|
|
4434
4434
|
"avatar",
|
|
4435
|
+
// The company's campaign-parameter mapping. Immediate, because it decides
|
|
4436
|
+
// what the edge captures and one held until Publish would not measure the
|
|
4437
|
+
// campaign it was written for.
|
|
4438
|
+
"analytics-mapping",
|
|
4435
4439
|
"briefs"
|
|
4436
4440
|
]);
|
|
4437
4441
|
var chatChangeActionSchema = z10.enum(["created", "updated", "deleted"]);
|
|
@@ -4777,7 +4781,8 @@ var historyCategorySchema = z12.enum([
|
|
|
4777
4781
|
"domain",
|
|
4778
4782
|
"hosting",
|
|
4779
4783
|
"integration",
|
|
4780
|
-
"tag_manager"
|
|
4784
|
+
"tag_manager",
|
|
4785
|
+
"analytics"
|
|
4781
4786
|
]);
|
|
4782
4787
|
var historyListRequestSchema = z12.object({
|
|
4783
4788
|
limit: z12.number().int().min(1).max(200).optional(),
|
|
@@ -10564,9 +10569,9 @@ async function fetchAllPages(body, args, servingOptions) {
|
|
|
10564
10569
|
let totalRowsWritten = 0;
|
|
10565
10570
|
let keywordLimits;
|
|
10566
10571
|
do {
|
|
10567
|
-
const
|
|
10568
|
-
if (pageToken)
|
|
10569
|
-
const response = await apiPost("/api/ads/google/query",
|
|
10572
|
+
const requestBody2 = { ...body };
|
|
10573
|
+
if (pageToken) requestBody2.pageToken = pageToken;
|
|
10574
|
+
const response = await apiPost("/api/ads/google/query", requestBody2);
|
|
10570
10575
|
const rows = response.rows ?? [];
|
|
10571
10576
|
pageToken = response.pageToken;
|
|
10572
10577
|
if (args.out) {
|
|
@@ -20344,11 +20349,527 @@ Full guides: __tooling__/docs/tools/baker/ads-<platform>.md (google|meta|linkedi
|
|
|
20344
20349
|
}
|
|
20345
20350
|
});
|
|
20346
20351
|
|
|
20352
|
+
// src/commands/analytics/index.ts
|
|
20353
|
+
import { defineCommand as defineCommand87 } from "citty";
|
|
20354
|
+
|
|
20355
|
+
// src/commands/analytics/hints.ts
|
|
20356
|
+
var SEVERE_STEP_DROP = 0.6;
|
|
20357
|
+
var MIN_SESSIONS_FOR_RATES = 100;
|
|
20358
|
+
var SHALLOW_ENGAGEMENT_MS = 1e4;
|
|
20359
|
+
function percent(value) {
|
|
20360
|
+
return `${Math.round(value * 100)}%`;
|
|
20361
|
+
}
|
|
20362
|
+
function buildAnalyticsHints(data) {
|
|
20363
|
+
const hints = [];
|
|
20364
|
+
for (const funnel of data.funnels ?? []) {
|
|
20365
|
+
const worst = funnel.worstStep;
|
|
20366
|
+
if (worst && worst.dropRate !== null && worst.dropRate >= SEVERE_STEP_DROP) {
|
|
20367
|
+
hints.push(
|
|
20368
|
+
`Form "${funnel.flowSlug}" loses ${percent(worst.dropRate)} of people at step "${worst.stepId}" \u2014 open the flow-builder skill and look at what that step asks for.`
|
|
20369
|
+
);
|
|
20370
|
+
}
|
|
20371
|
+
}
|
|
20372
|
+
if (data.totals.sessions > 0 && data.totals.sessions < MIN_SESSIONS_FOR_RATES) {
|
|
20373
|
+
hints.push(
|
|
20374
|
+
"Too few sessions to read rates as reliable \u2014 report the absolute numbers and say the period is small, rather than quoting a conversion rate."
|
|
20375
|
+
);
|
|
20376
|
+
}
|
|
20377
|
+
if (data.totals.avgEngagementMs !== null && data.totals.avgEngagementMs < SHALLOW_ENGAGEMENT_MS) {
|
|
20378
|
+
hints.push(
|
|
20379
|
+
"Visitors leave in under ten seconds on average \u2014 that is usually a mismatch between the ad and the page, not a form problem. Check the top sources against the page's headline."
|
|
20380
|
+
);
|
|
20381
|
+
}
|
|
20382
|
+
if (data.totals.pageViews > 0 && data.totals.sessions === 0) {
|
|
20383
|
+
hints.push(
|
|
20384
|
+
"Pages were served but no sessions were counted \u2014 visitors are declining analytics consent, so traffic is measurable and per-visitor behaviour is not. Say so rather than reporting zero visitors."
|
|
20385
|
+
);
|
|
20386
|
+
}
|
|
20387
|
+
if ((data.topCampaigns ?? []).length === 0 && (data.topSources ?? []).length > 0) {
|
|
20388
|
+
hints.push(
|
|
20389
|
+
"No campaign tagging on any traffic \u2014 ad clicks cannot be attributed to a campaign until the destination URLs carry utm parameters."
|
|
20390
|
+
);
|
|
20391
|
+
}
|
|
20392
|
+
return hints;
|
|
20393
|
+
}
|
|
20394
|
+
|
|
20395
|
+
// src/commands/analytics/presets.ts
|
|
20396
|
+
var ANALYTICS_PRESET_INFO = [
|
|
20397
|
+
{
|
|
20398
|
+
name: "overview",
|
|
20399
|
+
description: "Everything at once: traffic, top pages with their conversion rates, where visitors came from, the worst step of every Form, and what the conversion number consists of \u2014 one row per outcome the company marked, by the name they gave it. Start here. A `conversions` row at zero means the outcome is marked and has never fired, which is usually a Form that never reaches it.",
|
|
20400
|
+
playbook: "landing \u2014 diagnose a page that gets traffic but few leads"
|
|
20401
|
+
},
|
|
20402
|
+
{
|
|
20403
|
+
name: "traffic",
|
|
20404
|
+
description: "Where visitors come from \u2014 trend, sources, campaigns, countries, devices.",
|
|
20405
|
+
playbook: "the platform playbook for the channel that dominates"
|
|
20406
|
+
},
|
|
20407
|
+
{
|
|
20408
|
+
name: "funnel",
|
|
20409
|
+
description: "Per-step drop-off for the company's Forms. Narrow to one with --flow.",
|
|
20410
|
+
playbook: "flow-builder \u2014 fix the step that loses people"
|
|
20411
|
+
},
|
|
20412
|
+
{
|
|
20413
|
+
name: "flow",
|
|
20414
|
+
description: "One Form in depth: conversions counted at the node that produced them, step-to-step paths for a branching Form, the per-step table, every trigger raised, and each marked conversion by name. Read convertedSessions rather than submits \u2014 a Form whose scheduling widget sits mid-flow never emits a submit and reports zero on every other report. An empty `conversions` array means nobody has marked what this Form is for, so the numbers rest on a built-in guess; mark it in the Forms builder or with `conversions: [{ triggerId }]` on the node.",
|
|
20415
|
+
playbook: "flow-builder \u2014 fix the branch or the step that loses people"
|
|
20416
|
+
},
|
|
20417
|
+
{
|
|
20418
|
+
name: "page",
|
|
20419
|
+
description: "One page in detail. Requires --path.",
|
|
20420
|
+
playbook: "landing"
|
|
20421
|
+
},
|
|
20422
|
+
{
|
|
20423
|
+
name: "triggers",
|
|
20424
|
+
description: "What visitors did inside a Form and how much of it fired a side effect \u2014 link clicks that leave the site, scheduling widgets, embedded checkouts. The funnel shows the steps they walked; this shows what they did. A trigger with many fires and no side effects is behaviour nobody is measuring yet.",
|
|
20425
|
+
playbook: "flow-builder \u2014 wire up what matters, or tags for what should be measured"
|
|
20426
|
+
},
|
|
20427
|
+
{
|
|
20428
|
+
name: "paid",
|
|
20429
|
+
description: "Paid campaigns, grouped by session rather than by page view, with the click ids that resolve to a real ad click \u2014 and, crucially, how many of those leads were actually DELIVERED to the CRM. A campaign whose forms all submit and whose integration is rejecting every one of them looks perfect on every other preset and reads as zero delivered here.",
|
|
20430
|
+
playbook: "the platform playbook for the channel \u2014 or tags, when the gap is delivery rather than acquisition"
|
|
20431
|
+
},
|
|
20432
|
+
{
|
|
20433
|
+
name: "delivery",
|
|
20434
|
+
description: 'Where each submission actually went: every destination it reached, whether that destination accepted it, and the id the destination gave the record it created. Failures only by default; --full lists every submission. This is the preset for "I filled in the form, where is my lead?".',
|
|
20435
|
+
playbook: "flow-builder \u2014 repair the destination that is refusing leads"
|
|
20436
|
+
},
|
|
20437
|
+
{
|
|
20438
|
+
name: "geo",
|
|
20439
|
+
description: "Where the people who convert actually are, at whatever resolution you ask for: country, region, city, postcode or US DMA. Country answers 'which market is this working in'; postcode answers the question a local advertiser is actually asking, and matches the unit Google and Meta sell that targeting in.",
|
|
20440
|
+
playbook: "the platform playbook for the channel \u2014 narrow the targeting to where it already works"
|
|
20441
|
+
},
|
|
20442
|
+
{
|
|
20443
|
+
name: "bots",
|
|
20444
|
+
description: "Which machines fetch this site and whether they are genuine. Every other report here excludes them; this one reads them. Answers whether Google is still crawling a page after it was republished, whether Meta fetched a link preview before spend went behind the URL, and how much of the traffic is now AI answer engines.",
|
|
20445
|
+
playbook: "landing \u2014 a page that stopped being crawled stops ranking, weeks before the traffic shows it"
|
|
20446
|
+
},
|
|
20447
|
+
{
|
|
20448
|
+
name: "landings",
|
|
20449
|
+
description: "Every landing side by side \u2014 views, entrances, conversion rate and a sparkline each, under the name a person gave it. Answers 'which of my pages is working' without having to know the answer first; `page` then answers one of them in depth. --tag narrows it to a campaign.",
|
|
20450
|
+
playbook: "landing \u2014 pick the page worth working on before working on one"
|
|
20451
|
+
},
|
|
20452
|
+
{
|
|
20453
|
+
name: "tags",
|
|
20454
|
+
description: "The same numbers rolled up by the tag a landing is filed under \u2014 the unit a campaign is actually run at. A client asks how the September push did, and September was six landings.",
|
|
20455
|
+
playbook: "the platform playbook for the channel \u2014 judge the campaign, not the page"
|
|
20456
|
+
},
|
|
20457
|
+
{
|
|
20458
|
+
name: "events",
|
|
20459
|
+
description: "Events the pages define for themselves: a section seen, a video played, a button clicked. Lists each with the property keys it carries so it can be broken down, and takes --steps for an ORDERED funnel over them \u2014 where a session only counts at a step if it reached it after the one before, so 'saw pricing then clicked demo' is not the same number as the reverse.",
|
|
20460
|
+
playbook: "landing \u2014 measure the part of the page the Form funnel cannot see"
|
|
20461
|
+
},
|
|
20462
|
+
{
|
|
20463
|
+
name: "devices",
|
|
20464
|
+
description: "Browser, OS, engine or viewport of real visitors, with the conversion rate of each. Narrow enough to reproduce a bug on: 'mobile converts worse' is not actionable, 'Safari 17 under 380px converts at a third of the rate' is.",
|
|
20465
|
+
playbook: "landing \u2014 fix the client the page is broken on"
|
|
20466
|
+
},
|
|
20467
|
+
{
|
|
20468
|
+
name: "releases",
|
|
20469
|
+
description: "Traffic and conversions per published build, newest first. Answers whether a change to a page moved the numbers.",
|
|
20470
|
+
playbook: "landing \u2014 compare a page before and after a change"
|
|
20471
|
+
}
|
|
20472
|
+
];
|
|
20473
|
+
|
|
20474
|
+
// src/commands/analytics/index.ts
|
|
20475
|
+
var SHARED_ARGS = {
|
|
20476
|
+
days: { type: "string", description: "Lookback window in days (default: 30)", required: false },
|
|
20477
|
+
"start-date": { type: "string", description: "Explicit start date (YYYY-MM-DD)", required: false },
|
|
20478
|
+
"end-date": { type: "string", description: "Explicit end date (YYYY-MM-DD, inclusive)", required: false },
|
|
20479
|
+
full: {
|
|
20480
|
+
type: "boolean",
|
|
20481
|
+
description: "Return long breakdowns and the per-day trend instead of the top few",
|
|
20482
|
+
required: false
|
|
20483
|
+
},
|
|
20484
|
+
timezone: {
|
|
20485
|
+
type: "string",
|
|
20486
|
+
description: "IANA zone the day boundaries are drawn in, e.g. Europe/Madrid (default: UTC). Pass the client's zone \u2014 in UTC, two hours of every Spanish evening land on the following day",
|
|
20487
|
+
required: false
|
|
20488
|
+
},
|
|
20489
|
+
granularity: {
|
|
20490
|
+
type: "string",
|
|
20491
|
+
description: "hour | day (default) | week | month \u2014 how wide one point of the trend is",
|
|
20492
|
+
required: false
|
|
20493
|
+
},
|
|
20494
|
+
compare: {
|
|
20495
|
+
type: "boolean",
|
|
20496
|
+
description: "Also return the preceding window of the same length, so every total has something to be read against",
|
|
20497
|
+
required: false
|
|
20498
|
+
},
|
|
20499
|
+
landing: {
|
|
20500
|
+
type: "string",
|
|
20501
|
+
description: "Narrow the whole report to one landing, by the internalId in its _definition.md \u2014 get it from `baker analytics landings`. Works on every report here: sources, geography, paid campaigns, Form drop-off and delivery all answer for that page alone. Prefer it over --path, which stops matching the moment a page is moved or renamed",
|
|
20502
|
+
required: false
|
|
20503
|
+
},
|
|
20504
|
+
role: {
|
|
20505
|
+
type: "string",
|
|
20506
|
+
description: 'Narrow the whole report to visits that arrived on one ad dimension: keyword, match_type, campaign_id, adgroup_id, ad_id, placement, network, audience, device, search_query and the rest \u2014 run `baker analytics ads` for the full list and what this company actually sends. Pair it with --value. It selects the VISITS that arrived on that value and keeps everything they then did, so `--role keyword --value "solar panels"` answers what those people read and whether they converted, not just where they landed',
|
|
20507
|
+
required: false
|
|
20508
|
+
},
|
|
20509
|
+
value: {
|
|
20510
|
+
type: "string",
|
|
20511
|
+
description: "The value of --role to narrow to. Pass an empty string to get the visits that arrived carrying no such parameter, which is how you size the untagged half of an account",
|
|
20512
|
+
required: false
|
|
20513
|
+
}
|
|
20514
|
+
};
|
|
20515
|
+
function handleError(err) {
|
|
20516
|
+
if (err instanceof ApiError) {
|
|
20517
|
+
writeJsonEnvelope({ ok: false, error: { code: err.code, message: err.message } });
|
|
20518
|
+
process.exit(1);
|
|
20519
|
+
}
|
|
20520
|
+
writeJsonEnvelope({
|
|
20521
|
+
ok: false,
|
|
20522
|
+
error: { code: "NETWORK_ERROR", message: err instanceof Error ? err.message : "Unexpected error" }
|
|
20523
|
+
});
|
|
20524
|
+
process.exit(1);
|
|
20525
|
+
}
|
|
20526
|
+
function requestBody(args, options) {
|
|
20527
|
+
const candidates = {
|
|
20528
|
+
preset: options.preset,
|
|
20529
|
+
days: args.days ? Number(args.days) : void 0,
|
|
20530
|
+
startDate: args["start-date"],
|
|
20531
|
+
endDate: args["end-date"],
|
|
20532
|
+
full: args.full ? true : void 0,
|
|
20533
|
+
compare: args.compare ? true : void 0,
|
|
20534
|
+
timezone: args.timezone ? String(args.timezone) : void 0,
|
|
20535
|
+
granularity: args.granularity ? String(args.granularity) : void 0,
|
|
20536
|
+
path: options.path,
|
|
20537
|
+
flowSlug: options.flowSlug,
|
|
20538
|
+
grain: options.grain,
|
|
20539
|
+
country: options.country,
|
|
20540
|
+
// Read off the shared flag unless a preset resolved one itself. Every
|
|
20541
|
+
// report takes it, so wiring it per-preset would be fifteen identical lines
|
|
20542
|
+
// and, historically, four of them missing.
|
|
20543
|
+
landingId: options.landingId ?? (args.landing ? String(args.landing) : void 0),
|
|
20544
|
+
tag: options.tag,
|
|
20545
|
+
eventName: options.eventName,
|
|
20546
|
+
property: options.property,
|
|
20547
|
+
where: options.where,
|
|
20548
|
+
steps: options.steps && options.steps.length > 0 ? options.steps : void 0,
|
|
20549
|
+
deviceGrain: options.deviceGrain,
|
|
20550
|
+
adRole: options.adRole ?? (args.role ? String(args.role) : void 0),
|
|
20551
|
+
// Deliberately not dropped when empty: with a role set, an empty value is a
|
|
20552
|
+
// real question — "the visits that arrived carrying none of these" — and the
|
|
20553
|
+
// filter below would otherwise strip it and silently widen the report to
|
|
20554
|
+
// everything.
|
|
20555
|
+
adValue: args.role !== void 0 && args.value !== void 0 ? String(args.value) : void 0
|
|
20556
|
+
};
|
|
20557
|
+
return Object.fromEntries(
|
|
20558
|
+
Object.entries(candidates).filter(([key, value]) => value !== void 0 && (value !== "" || key === "adValue"))
|
|
20559
|
+
);
|
|
20560
|
+
}
|
|
20561
|
+
async function runPreset(args, options) {
|
|
20562
|
+
try {
|
|
20563
|
+
const response = await apiPost("/api/analytics/query", requestBody(args, options));
|
|
20564
|
+
const hints = buildAnalyticsHints(response.data);
|
|
20565
|
+
writeJsonEnvelope({ ...response, ...hints.length > 0 ? { hints } : {} });
|
|
20566
|
+
} catch (err) {
|
|
20567
|
+
handleError(err);
|
|
20568
|
+
}
|
|
20569
|
+
}
|
|
20570
|
+
function presetCommand(options) {
|
|
20571
|
+
registerSchema({
|
|
20572
|
+
command: `analytics.${options.name}`,
|
|
20573
|
+
description: options.description,
|
|
20574
|
+
args: { ...SHARED_ARGS, ...options.extraArgs ?? {} }
|
|
20575
|
+
});
|
|
20576
|
+
return defineCommand87({
|
|
20577
|
+
meta: { name: options.name, description: options.description },
|
|
20578
|
+
args: { ...SHARED_ARGS, ...options.extraArgs ?? {} },
|
|
20579
|
+
run: async ({ args }) => {
|
|
20580
|
+
const resolved = options.resolve ? options.resolve(args) : { preset: options.preset };
|
|
20581
|
+
if ("error" in resolved) {
|
|
20582
|
+
writeJsonEnvelope({ ok: false, error: { code: "VALIDATION_ERROR", message: resolved.error } });
|
|
20583
|
+
process.exit(1);
|
|
20584
|
+
}
|
|
20585
|
+
await runPreset(args, resolved);
|
|
20586
|
+
}
|
|
20587
|
+
});
|
|
20588
|
+
}
|
|
20589
|
+
var overviewCommand = presetCommand({
|
|
20590
|
+
name: "overview",
|
|
20591
|
+
preset: "overview",
|
|
20592
|
+
description: "Start here: traffic, top pages and their conversion rates, where visitors came from, and the worst step of every Form \u2014 in one call."
|
|
20593
|
+
});
|
|
20594
|
+
var trafficCommand = presetCommand({
|
|
20595
|
+
name: "traffic",
|
|
20596
|
+
preset: "traffic",
|
|
20597
|
+
description: "Where visitors come from \u2014 trend, sources, campaigns, countries and devices."
|
|
20598
|
+
});
|
|
20599
|
+
var funnelCommand = presetCommand({
|
|
20600
|
+
name: "funnel",
|
|
20601
|
+
preset: "funnel",
|
|
20602
|
+
description: "Per-step drop-off for the company's Forms. Narrow to one with --flow.",
|
|
20603
|
+
extraArgs: { flow: { type: "string", description: "Form slug (default: every Form)", required: false } },
|
|
20604
|
+
resolve: (args) => ({ preset: "funnel", flowSlug: args.flow ? String(args.flow) : void 0 })
|
|
20605
|
+
});
|
|
20606
|
+
var flowCommand = presetCommand({
|
|
20607
|
+
name: "flow",
|
|
20608
|
+
preset: "flow",
|
|
20609
|
+
description: "One Form in depth: how many people it converted, where they went between steps, the per-step table, and every trigger it raised. Read `flowSummary.convertedSessions`, not `submits` \u2014 a Form that books a call on a scheduling node in the MIDDLE of the flow never emits a submit, so it reports zero submits and every one of its real bookings as conversions. `flowPaths` is the flow as edges between steps, bracketed by __flow_start__, __flow_converted__ and __flow_exit__, which is how a branching Form is read at all: a per-step table cannot say that of the people who left step two, forty went to the booking branch and ninety went nowhere.",
|
|
20610
|
+
extraArgs: { flow: { type: "string", description: "Form slug (default: every Form)", required: false } },
|
|
20611
|
+
resolve: (args) => ({ preset: "flow", flowSlug: args.flow ? String(args.flow) : void 0 })
|
|
20612
|
+
});
|
|
20613
|
+
var pageCommand = presetCommand({
|
|
20614
|
+
name: "page",
|
|
20615
|
+
preset: "page",
|
|
20616
|
+
description: "One page in detail \u2014 its traffic, entrances, engagement and conversion rate.",
|
|
20617
|
+
extraArgs: { path: { type: "string", description: "Page path, e.g. /pricing (no trailing slash)", required: true } },
|
|
20618
|
+
resolve: (args) => args.path ? { preset: "page", path: String(args.path) } : {
|
|
20619
|
+
error: "Provide --path, e.g. --path /pricing. Run `baker analytics overview` to see which paths have traffic."
|
|
20620
|
+
}
|
|
20621
|
+
});
|
|
20622
|
+
var triggersCommand = presetCommand({
|
|
20623
|
+
name: "triggers",
|
|
20624
|
+
preset: "triggers",
|
|
20625
|
+
description: "What visitors actually do inside a Form \u2014 link clicks that send them off the site, scheduling widgets, embedded checkouts \u2014 and how much of it fires a side effect. Narrow to one Form with --flow.",
|
|
20626
|
+
extraArgs: { flow: { type: "string", description: "Form slug (default: every Form)", required: false } },
|
|
20627
|
+
resolve: (args) => ({ preset: "triggers", flowSlug: args.flow ? String(args.flow) : void 0 })
|
|
20628
|
+
});
|
|
20629
|
+
var releasesCommand = presetCommand({
|
|
20630
|
+
name: "releases",
|
|
20631
|
+
preset: "releases",
|
|
20632
|
+
description: "Traffic and conversions per published build, newest first. Use it to tell whether a change to a page moved the numbers, instead of guessing from the date."
|
|
20633
|
+
});
|
|
20634
|
+
var paidCommand = presetCommand({
|
|
20635
|
+
name: "paid",
|
|
20636
|
+
preset: "paid",
|
|
20637
|
+
description: "Paid campaigns, counted per visit rather than per page view, with the click ids that resolve to a real ad click \u2014 and how many of those leads were actually delivered. A campaign whose forms all submit while the CRM rejects every one of them reads as perfect everywhere else and as zero delivered here."
|
|
20638
|
+
});
|
|
20639
|
+
var deliveryCommand = presetCommand({
|
|
20640
|
+
name: "delivery",
|
|
20641
|
+
preset: "delivery",
|
|
20642
|
+
description: "Where each submission went: every destination it reached, whether that destination accepted it, and the id it gave the record it created. Failures first; --full lists every submission. Start here when someone says a lead never arrived."
|
|
20643
|
+
});
|
|
20644
|
+
var geoCommand = presetCommand({
|
|
20645
|
+
name: "geo",
|
|
20646
|
+
preset: "geo",
|
|
20647
|
+
description: "Where the people who convert actually are. Country by default; --grain city|postal_code|metro_code goes finer, and --country narrows first so postcodes do not collide across markets. Use this when the campaign is local \u2014 a radius around a branch is a set of postcodes, never a set of countries.",
|
|
20648
|
+
extraArgs: {
|
|
20649
|
+
grain: {
|
|
20650
|
+
type: "string",
|
|
20651
|
+
description: "country (default) | region | city | postal_code | metro_code",
|
|
20652
|
+
required: false
|
|
20653
|
+
},
|
|
20654
|
+
country: { type: "string", description: "Two-letter code to look inside, e.g. ES", required: false }
|
|
20655
|
+
},
|
|
20656
|
+
resolve: (args) => ({
|
|
20657
|
+
preset: "geo",
|
|
20658
|
+
grain: args.grain ? String(args.grain) : void 0,
|
|
20659
|
+
country: args.country ? String(args.country) : void 0
|
|
20660
|
+
})
|
|
20661
|
+
});
|
|
20662
|
+
var botsCommand = presetCommand({
|
|
20663
|
+
name: "bots",
|
|
20664
|
+
preset: "bots",
|
|
20665
|
+
description: "Which machines are fetching this site \u2014 search crawlers, AI answer engines, link-preview scrapers, SEO tools \u2014 and whether each one is genuine or only claims to be. Every other report excludes these; this is the one that reads them. Use it to check that a republished page is still being crawled, or that Meta fetched a link preview before spend goes behind the URL."
|
|
20666
|
+
});
|
|
20667
|
+
var landingsCommand = presetCommand({
|
|
20668
|
+
name: "landings",
|
|
20669
|
+
preset: "landings",
|
|
20670
|
+
description: "Every landing side by side \u2014 views, entrances, conversion rate and a sparkline each, under the name a person gave it rather than its id. This is the one that answers 'which of my pages is working' without having to know the answer first; `page` answers one page in depth once this has named it. Narrow to a campaign with --tag.",
|
|
20671
|
+
extraArgs: {
|
|
20672
|
+
tag: { type: "string", description: "Only landings filed under this tag", required: false }
|
|
20673
|
+
},
|
|
20674
|
+
resolve: (args) => ({ preset: "landings", tag: args.tag ? String(args.tag) : void 0 })
|
|
20675
|
+
});
|
|
20676
|
+
var tagsCommand2 = presetCommand({
|
|
20677
|
+
name: "tags",
|
|
20678
|
+
preset: "tags",
|
|
20679
|
+
description: "The same numbers grouped by the tag a landing is filed under \u2014 the unit a campaign is actually run at. Nobody asks how /pricing-b did; they ask how the September push did, and September was six landings. Tags are declared in each landing's _definition.md."
|
|
20680
|
+
});
|
|
20681
|
+
var eventsCommand = presetCommand({
|
|
20682
|
+
name: "events",
|
|
20683
|
+
preset: "events",
|
|
20684
|
+
description: "Events the pages define for themselves \u2014 a section scrolled into view, a video played, a button clicked. Lists each one with the property keys it carries, so you can then break it down: --event video --property milestone. Pass --steps a,b,c for an ORDERED funnel over them, where a session only counts at each step if it got there after the one before.",
|
|
20685
|
+
extraArgs: {
|
|
20686
|
+
event: { type: "string", description: "Break this one event down (needs --property too)", required: false },
|
|
20687
|
+
property: { type: "string", description: "Which of that event's property keys to group by", required: false },
|
|
20688
|
+
where: {
|
|
20689
|
+
type: "string",
|
|
20690
|
+
description: "Narrow to one property value before grouping, as key=value \u2014 e.g. --event vsl --property milestone --where autoplay=0 for the retention curve of the videos visitors chose to play, rather than the one a muted hero produces on its own",
|
|
20691
|
+
required: false
|
|
20692
|
+
},
|
|
20693
|
+
steps: {
|
|
20694
|
+
type: "string",
|
|
20695
|
+
description: "Comma-separated event names, in order, for a funnel \u2014 e.g. hero_view,pricing_view,demo_click",
|
|
20696
|
+
required: false
|
|
20697
|
+
}
|
|
20698
|
+
},
|
|
20699
|
+
resolve: (args) => {
|
|
20700
|
+
const steps = args.steps ? String(args.steps).split(",").map((step) => step.trim()).filter((step) => step !== "") : void 0;
|
|
20701
|
+
if (args.property && !args.event) {
|
|
20702
|
+
return {
|
|
20703
|
+
error: "Breaking an event down by a property needs --event too, e.g. --event video --property milestone"
|
|
20704
|
+
};
|
|
20705
|
+
}
|
|
20706
|
+
if (steps && steps.length < 2) {
|
|
20707
|
+
return { error: "A funnel needs at least two steps, e.g. --steps hero_view,pricing_view" };
|
|
20708
|
+
}
|
|
20709
|
+
let where;
|
|
20710
|
+
if (args.where) {
|
|
20711
|
+
const raw = String(args.where);
|
|
20712
|
+
const at = raw.indexOf("=");
|
|
20713
|
+
if (at < 1) {
|
|
20714
|
+
return { error: "--where takes key=value, e.g. --where autoplay=0" };
|
|
20715
|
+
}
|
|
20716
|
+
if (!args.property) {
|
|
20717
|
+
return { error: "--where narrows a breakdown, so it needs --event and --property too" };
|
|
20718
|
+
}
|
|
20719
|
+
where = { property: raw.slice(0, at), value: raw.slice(at + 1) };
|
|
20720
|
+
}
|
|
20721
|
+
return {
|
|
20722
|
+
preset: "events",
|
|
20723
|
+
eventName: args.event ? String(args.event) : void 0,
|
|
20724
|
+
property: args.property ? String(args.property) : void 0,
|
|
20725
|
+
where,
|
|
20726
|
+
steps
|
|
20727
|
+
};
|
|
20728
|
+
}
|
|
20729
|
+
});
|
|
20730
|
+
var devicesCommand = presetCommand({
|
|
20731
|
+
name: "devices",
|
|
20732
|
+
preset: "devices",
|
|
20733
|
+
description: "What visitors are actually using, narrow enough to reproduce a bug on: browser and version, OS and version, rendering engine, or viewport width. `traffic` says mobile converts worse; this says it is Safari 17 on viewports under 380px, which is a browser you can open and a width you can resize to.",
|
|
20734
|
+
extraArgs: {
|
|
20735
|
+
grain: {
|
|
20736
|
+
type: "string",
|
|
20737
|
+
description: "browser (default) | os | engine | device | viewport",
|
|
20738
|
+
required: false
|
|
20739
|
+
}
|
|
20740
|
+
},
|
|
20741
|
+
resolve: (args) => ({
|
|
20742
|
+
preset: "devices",
|
|
20743
|
+
deviceGrain: args.grain ? String(args.grain) : void 0
|
|
20744
|
+
})
|
|
20745
|
+
});
|
|
20746
|
+
var presetsCommand = defineCommand87({
|
|
20747
|
+
meta: { name: "presets", description: "List the available reports and what each answers." },
|
|
20748
|
+
run: () => {
|
|
20749
|
+
writeJsonEnvelope({ ok: true, data: ANALYTICS_PRESET_INFO });
|
|
20750
|
+
}
|
|
20751
|
+
});
|
|
20752
|
+
var adsCommand3 = presetCommand({
|
|
20753
|
+
name: "ads",
|
|
20754
|
+
preset: "ads",
|
|
20755
|
+
description: "What the ad platforms told us about each click, and what those people then did. `--role keyword` breaks the window down by keyword with conversions AND bounced visits beside each one \u2014 the ad platform can tell you a keyword got clicks, only this can tell you the people it brought left immediately. `adParams` comes back either way: it is every campaign parameter arriving on this company's URLs, whether we can read it or not. A parameter with no `role` is one nobody has told us the meaning of, and until somebody does its values are not stored at all \u2014 only the fact that the name appeared. Map it with `baker analytics map`.",
|
|
20756
|
+
extraArgs: {}
|
|
20757
|
+
});
|
|
20758
|
+
var mapCommand = (() => {
|
|
20759
|
+
const args = {
|
|
20760
|
+
set: {
|
|
20761
|
+
type: "string",
|
|
20762
|
+
description: "Parameter=role pairs, comma separated: --set kw=keyword,mt=match_type. Roles come from `baker analytics ads` (every row lists the role in force). Use the role `other` for a parameter worth capturing that means nothing to us \u2014 it is then stored and filterable by its own name, which is better than not stored at all",
|
|
20763
|
+
required: false
|
|
20764
|
+
},
|
|
20765
|
+
remove: {
|
|
20766
|
+
type: "string",
|
|
20767
|
+
description: "Parameter names to stop reading, comma separated. Only affects this company's own entries",
|
|
20768
|
+
required: false
|
|
20769
|
+
}
|
|
20770
|
+
};
|
|
20771
|
+
registerSchema({
|
|
20772
|
+
command: "analytics.map",
|
|
20773
|
+
description: "Set how this company's campaign URLs spell each ad dimension",
|
|
20774
|
+
args
|
|
20775
|
+
});
|
|
20776
|
+
return defineCommand87({
|
|
20777
|
+
meta: {
|
|
20778
|
+
name: "map",
|
|
20779
|
+
description: "Teach Baker how this company's campaign URLs spell each ad dimension \u2014 `--set kw=keyword`. Run it with no flags to see the mapping in force. Only needed when they tag differently from the templates we hand out; the ordinary spellings are already understood. Takes effect within seconds. Renaming a parameter Baker already captured fixes the history too, because roles are applied when a report is read; naming one it never read only starts collecting it, since no value was stored."
|
|
20780
|
+
},
|
|
20781
|
+
args,
|
|
20782
|
+
run: async ({ args: raw }) => {
|
|
20783
|
+
try {
|
|
20784
|
+
const body = {
|
|
20785
|
+
set: parsePairs(raw.set === void 0 ? void 0 : String(raw.set)),
|
|
20786
|
+
remove: parseList(raw.remove === void 0 ? void 0 : String(raw.remove))
|
|
20787
|
+
};
|
|
20788
|
+
const response = await apiPost("/api/analytics/mapping", body);
|
|
20789
|
+
writeJsonEnvelope(response);
|
|
20790
|
+
} catch (err) {
|
|
20791
|
+
handleError(err);
|
|
20792
|
+
}
|
|
20793
|
+
}
|
|
20794
|
+
});
|
|
20795
|
+
})();
|
|
20796
|
+
function parsePairs(raw) {
|
|
20797
|
+
if (raw === void 0) return void 0;
|
|
20798
|
+
const out = {};
|
|
20799
|
+
for (const pair of raw.split(",")) {
|
|
20800
|
+
const [name, role] = pair.split("=");
|
|
20801
|
+
if (name?.trim() && role?.trim()) out[name.trim()] = role.trim();
|
|
20802
|
+
}
|
|
20803
|
+
return out;
|
|
20804
|
+
}
|
|
20805
|
+
function parseList(raw) {
|
|
20806
|
+
if (raw === void 0) return void 0;
|
|
20807
|
+
const out = raw.split(",").map((entry) => entry.trim()).filter((entry) => entry !== "");
|
|
20808
|
+
return out.length > 0 ? out : void 0;
|
|
20809
|
+
}
|
|
20810
|
+
var analyticsCommand2 = defineCommand87({
|
|
20811
|
+
meta: {
|
|
20812
|
+
name: "analytics",
|
|
20813
|
+
description: `Baker's own web analytics for this company's published pages. No connection to set up \u2014 data starts the moment a page is published.
|
|
20814
|
+
|
|
20815
|
+
Start here:
|
|
20816
|
+
baker analytics overview \u2014 traffic, pages, sources and Form drop-off in one call
|
|
20817
|
+
baker analytics landings \u2014 every page side by side, with a sparkline each
|
|
20818
|
+
baker analytics presets \u2014 what each report answers
|
|
20819
|
+
|
|
20820
|
+
Examples:
|
|
20821
|
+
baker analytics overview --days 7
|
|
20822
|
+
baker analytics funnel --flow contact \u2014 which step loses people
|
|
20823
|
+
baker analytics flow --flow contact \u2014 that Form in depth: conversions, step-to-step paths, triggers
|
|
20824
|
+
baker analytics overview --landing ld_7f2a \u2014 the whole report for one page only
|
|
20825
|
+
baker analytics page --path /pricing \u2014 one page in detail
|
|
20826
|
+
baker analytics triggers --flow contact \u2014 what people did in the Form, wired up or not
|
|
20827
|
+
baker analytics paid --days 30 \u2014 campaigns by click id, and how many leads actually arrived
|
|
20828
|
+
baker analytics delivery \u2014 submissions whose destination refused them
|
|
20829
|
+
baker analytics releases \u2014 did the last publish change anything
|
|
20830
|
+
baker analytics traffic --days 90 --full \u2014 full breakdowns and the per-day trend
|
|
20831
|
+
baker analytics geo --grain postal_code --country ES \u2014 which postcodes convert
|
|
20832
|
+
baker analytics bots --days 30 \u2014 is the site still being crawled
|
|
20833
|
+
baker analytics landings --tag q3 \u2014 how the Q3 campaign's pages did
|
|
20834
|
+
baker analytics tags \u2014 the same numbers rolled up per campaign
|
|
20835
|
+
baker analytics events --event video --property milestone \u2014 how far people watch
|
|
20836
|
+
baker analytics events --event video --property milestone --where autoplay=0 \u2014 ...among videos they chose to play
|
|
20837
|
+
baker analytics events --steps hero_view,pricing_view,demo_click \u2014 an ordered page funnel
|
|
20838
|
+
baker analytics devices --grain viewport \u2014 which widths the page has to survive
|
|
20839
|
+
baker analytics ads \u2014 every campaign parameter on this company's URLs, and what we make of it
|
|
20840
|
+
baker analytics ads --role keyword \u2014 keywords by conversions AND by how many bounced
|
|
20841
|
+
baker analytics overview --role keyword --value "solar panels" \u2014 the whole report for those visits only
|
|
20842
|
+
baker analytics map --set kw=keyword \u2014 teach it a parameter name this company uses
|
|
20843
|
+
baker analytics overview --compare \u2014 this window against the one before it
|
|
20844
|
+
Full guide: __tooling__/docs/tools/baker/analytics.md`
|
|
20845
|
+
},
|
|
20846
|
+
subCommands: {
|
|
20847
|
+
overview: overviewCommand,
|
|
20848
|
+
traffic: trafficCommand,
|
|
20849
|
+
funnel: funnelCommand,
|
|
20850
|
+
flow: flowCommand,
|
|
20851
|
+
page: pageCommand,
|
|
20852
|
+
triggers: triggersCommand,
|
|
20853
|
+
releases: releasesCommand,
|
|
20854
|
+
paid: paidCommand,
|
|
20855
|
+
delivery: deliveryCommand,
|
|
20856
|
+
geo: geoCommand,
|
|
20857
|
+
bots: botsCommand,
|
|
20858
|
+
landings: landingsCommand,
|
|
20859
|
+
tags: tagsCommand2,
|
|
20860
|
+
events: eventsCommand,
|
|
20861
|
+
devices: devicesCommand,
|
|
20862
|
+
ads: adsCommand3,
|
|
20863
|
+
map: mapCommand,
|
|
20864
|
+
presets: presetsCommand
|
|
20865
|
+
}
|
|
20866
|
+
});
|
|
20867
|
+
|
|
20347
20868
|
// src/commands/avatars/index.ts
|
|
20348
|
-
import { defineCommand as
|
|
20869
|
+
import { defineCommand as defineCommand93 } from "citty";
|
|
20349
20870
|
|
|
20350
20871
|
// src/commands/avatars/create.ts
|
|
20351
|
-
import { defineCommand as
|
|
20872
|
+
import { defineCommand as defineCommand88 } from "citty";
|
|
20352
20873
|
|
|
20353
20874
|
// src/commands/avatars/casting.ts
|
|
20354
20875
|
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.";
|
|
@@ -20615,7 +21136,7 @@ registerSchema({
|
|
|
20615
21136
|
"voice-description": { type: "string", description: "How the voice should sound", required: false }
|
|
20616
21137
|
}
|
|
20617
21138
|
});
|
|
20618
|
-
var createCommand2 =
|
|
21139
|
+
var createCommand2 = defineCommand88({
|
|
20619
21140
|
meta: {
|
|
20620
21141
|
name: "create",
|
|
20621
21142
|
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.'
|
|
@@ -20696,7 +21217,7 @@ var createCommand2 = defineCommand87({
|
|
|
20696
21217
|
});
|
|
20697
21218
|
|
|
20698
21219
|
// src/commands/avatars/delete.ts
|
|
20699
|
-
import { defineCommand as
|
|
21220
|
+
import { defineCommand as defineCommand89 } from "citty";
|
|
20700
21221
|
registerSchema({
|
|
20701
21222
|
command: "avatars.delete",
|
|
20702
21223
|
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.",
|
|
@@ -20711,7 +21232,7 @@ registerSchema({
|
|
|
20711
21232
|
"dry-run": { type: "boolean", description: "Preview without removing anything", required: false, default: false }
|
|
20712
21233
|
}
|
|
20713
21234
|
});
|
|
20714
|
-
var deleteCommand =
|
|
21235
|
+
var deleteCommand = defineCommand89({
|
|
20715
21236
|
meta: {
|
|
20716
21237
|
name: "delete",
|
|
20717
21238
|
description: "Remove an avatar. Prefer --archive (retire, past work still resolves) over a hard delete. Example: baker avatars delete marta --archive --dry-run"
|
|
@@ -20745,7 +21266,7 @@ var deleteCommand = defineCommand88({
|
|
|
20745
21266
|
});
|
|
20746
21267
|
|
|
20747
21268
|
// src/commands/avatars/get.ts
|
|
20748
|
-
import { defineCommand as
|
|
21269
|
+
import { defineCommand as defineCommand90 } from "citty";
|
|
20749
21270
|
registerSchema({
|
|
20750
21271
|
command: "avatars.get",
|
|
20751
21272
|
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).",
|
|
@@ -20759,7 +21280,7 @@ registerSchema({
|
|
|
20759
21280
|
}
|
|
20760
21281
|
}
|
|
20761
21282
|
});
|
|
20762
|
-
var getCommand2 =
|
|
21283
|
+
var getCommand2 = defineCommand90({
|
|
20763
21284
|
meta: {
|
|
20764
21285
|
name: "get",
|
|
20765
21286
|
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"
|
|
@@ -20800,7 +21321,7 @@ var getCommand2 = defineCommand89({
|
|
|
20800
21321
|
});
|
|
20801
21322
|
|
|
20802
21323
|
// src/commands/avatars/list.ts
|
|
20803
|
-
import { defineCommand as
|
|
21324
|
+
import { defineCommand as defineCommand91 } from "citty";
|
|
20804
21325
|
var STATUSES = ["generating", "ready", "error", "archived"];
|
|
20805
21326
|
registerSchema({
|
|
20806
21327
|
command: "avatars.list",
|
|
@@ -20815,7 +21336,7 @@ registerSchema({
|
|
|
20815
21336
|
limit: { type: "number", description: "Max avatars to return (1-100)", required: false }
|
|
20816
21337
|
}
|
|
20817
21338
|
});
|
|
20818
|
-
var listCommand10 =
|
|
21339
|
+
var listCommand10 = defineCommand91({
|
|
20819
21340
|
meta: {
|
|
20820
21341
|
name: "list",
|
|
20821
21342
|
description: "List the company's avatars (reusable AI presenters). Only `ready` ones can be cast. Example: baker avatars list --status ready --output md"
|
|
@@ -20849,7 +21370,7 @@ var listCommand10 = defineCommand90({
|
|
|
20849
21370
|
});
|
|
20850
21371
|
|
|
20851
21372
|
// src/commands/avatars/update.ts
|
|
20852
|
-
import { defineCommand as
|
|
21373
|
+
import { defineCommand as defineCommand92 } from "citty";
|
|
20853
21374
|
function readUpdateArgs(args) {
|
|
20854
21375
|
const handle = (args.handle || args["avatar-handle"])?.trim();
|
|
20855
21376
|
if (!handle) {
|
|
@@ -20910,7 +21431,7 @@ registerSchema({
|
|
|
20910
21431
|
}
|
|
20911
21432
|
}
|
|
20912
21433
|
});
|
|
20913
|
-
var updateCommand2 =
|
|
21434
|
+
var updateCommand2 = defineCommand92({
|
|
20914
21435
|
meta: {
|
|
20915
21436
|
name: "update",
|
|
20916
21437
|
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'
|
|
@@ -20973,7 +21494,7 @@ var updateCommand2 = defineCommand91({
|
|
|
20973
21494
|
});
|
|
20974
21495
|
|
|
20975
21496
|
// src/commands/avatars/index.ts
|
|
20976
|
-
var avatarsCommand =
|
|
21497
|
+
var avatarsCommand = defineCommand93({
|
|
20977
21498
|
meta: {
|
|
20978
21499
|
name: "avatars",
|
|
20979
21500
|
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.
|
|
@@ -21003,12 +21524,12 @@ Full guide: __tooling__/docs/tools/baker/avatars.md`
|
|
|
21003
21524
|
});
|
|
21004
21525
|
|
|
21005
21526
|
// src/commands/brand/index.ts
|
|
21006
|
-
import { defineCommand as
|
|
21527
|
+
import { defineCommand as defineCommand95 } from "citty";
|
|
21007
21528
|
|
|
21008
21529
|
// src/commands/brand/fonts.ts
|
|
21009
21530
|
import { mkdir, readdir, readFile as readFile2, writeFile } from "fs/promises";
|
|
21010
21531
|
import path2 from "path";
|
|
21011
|
-
import { defineCommand as
|
|
21532
|
+
import { defineCommand as defineCommand94 } from "citty";
|
|
21012
21533
|
|
|
21013
21534
|
// src/engine/brand/fonts.ts
|
|
21014
21535
|
import { posix } from "path";
|
|
@@ -21606,7 +22127,6 @@ function asAuthored(css, normalized) {
|
|
|
21606
22127
|
function unresolvedBrandFamilies(css) {
|
|
21607
22128
|
const declared = [...parseBrandTokens(css, "").fonts].filter((family) => !GENERIC_FAMILIES.has(family));
|
|
21608
22129
|
const loaded = fontFaceFamilies(css);
|
|
21609
|
-
for (const request of googleFontRequests(stripCssComments(css))) loaded.add(normalizeFamily(request.family));
|
|
21610
22130
|
return declared.filter((family) => !loaded.has(family)).map((family) => asAuthored(css, family));
|
|
21611
22131
|
}
|
|
21612
22132
|
function stripFontFaceBlocks(source, family, styles) {
|
|
@@ -21761,7 +22281,7 @@ function fetchHints({
|
|
|
21761
22281
|
// The remedy is provider-specific: only a Google family has an @import
|
|
21762
22282
|
// to fall back on, and telling an agent to keep one for a Fontsource
|
|
21763
22283
|
// family sends it to write an import Google will 400.
|
|
21764
|
-
provider === "google" ? `PARTIAL: ${incomplete.join(", ")} did not download and is NOT in the \`fontFace\` block.
|
|
22284
|
+
provider === "google" ? `PARTIAL: ${incomplete.join(", ")} did not download and is NOT in the \`fontFace\` block. Re-run \`baker brand fonts fetch "${family}" --weights ${incomplete.join(",")}\` \u2014 a Google @import cannot cover those weights, because the build drops it before the page loads.` : `PARTIAL: ${incomplete.join(", ")} did not download and is NOT in the \`fontFace\` block. ${PROVIDER_LABEL[provider]} does not serve them, so re-run \`baker brand fonts fetch "${family}" --weights ${downloadedWeights.join(",")}\` and record only those weights in src/brand/BRAND.md.`
|
|
21765
22285
|
] : [],
|
|
21766
22286
|
`Licensing: ${PROVIDER_LABEL[provider]} carries open-licensed families, which are safe to self-host. A client's own commercial face is not \u2014 confirm before re-hosting one.`
|
|
21767
22287
|
];
|
|
@@ -21853,10 +22373,10 @@ async function unresolvedAction(css, unresolved) {
|
|
|
21853
22373
|
}
|
|
21854
22374
|
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}.`;
|
|
21855
22375
|
}
|
|
21856
|
-
var fontsCheckCommand =
|
|
22376
|
+
var fontsCheckCommand = defineCommand94({
|
|
21857
22377
|
meta: {
|
|
21858
22378
|
name: "check",
|
|
21859
|
-
description: "Verify the brand's fonts really exist. First: every --font-* family in src/styles/global.css must be provided by
|
|
22379
|
+
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."
|
|
21860
22380
|
},
|
|
21861
22381
|
async run() {
|
|
21862
22382
|
const css = await readGlobalCss();
|
|
@@ -21865,7 +22385,7 @@ var fontsCheckCommand = defineCommand93({
|
|
|
21865
22385
|
if (unresolved.length > 0) {
|
|
21866
22386
|
fail("FONT_NOT_LOADED", `Nothing loads ${unresolved.map((f) => `"${f}"`).join(", ")} in ${GLOBAL_CSS}.`, {
|
|
21867
22387
|
action: await unresolvedAction(css, unresolved),
|
|
21868
|
-
explanation: "The family is declared as a brand font but no @font-face
|
|
22388
|
+
explanation: "The family is declared as a brand font but no @font-face provides it, so every page silently renders a fallback. A Google @import does not count: Astro merges component CSS ahead of global.css into one inlined <style>, so the import lands after rules and the browser drops it \u2014 measured on a live client site. The client's verify fails on this too.",
|
|
21869
22389
|
unresolved
|
|
21870
22390
|
});
|
|
21871
22391
|
}
|
|
@@ -21905,7 +22425,7 @@ var fontsCheckCommand = defineCommand93({
|
|
|
21905
22425
|
});
|
|
21906
22426
|
}
|
|
21907
22427
|
});
|
|
21908
|
-
var fontsFetchCommand =
|
|
22428
|
+
var fontsFetchCommand = defineCommand94({
|
|
21909
22429
|
meta: {
|
|
21910
22430
|
name: "fetch",
|
|
21911
22431
|
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."
|
|
@@ -22006,7 +22526,7 @@ async function astroSources() {
|
|
|
22006
22526
|
}
|
|
22007
22527
|
return out;
|
|
22008
22528
|
}
|
|
22009
|
-
var fontsAdoptCommand =
|
|
22529
|
+
var fontsAdoptCommand = defineCommand94({
|
|
22010
22530
|
meta: {
|
|
22011
22531
|
name: "adopt",
|
|
22012
22532
|
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."
|
|
@@ -22086,7 +22606,7 @@ var fontsAdoptCommand = defineCommand93({
|
|
|
22086
22606
|
});
|
|
22087
22607
|
}
|
|
22088
22608
|
});
|
|
22089
|
-
var fontsCommand =
|
|
22609
|
+
var fontsCommand = defineCommand94({
|
|
22090
22610
|
meta: {
|
|
22091
22611
|
name: "fonts",
|
|
22092
22612
|
description: `Verify and self-host the brand's typefaces.
|
|
@@ -22106,7 +22626,7 @@ Subcommands:
|
|
|
22106
22626
|
});
|
|
22107
22627
|
|
|
22108
22628
|
// src/commands/brand/index.ts
|
|
22109
|
-
var brandCommand =
|
|
22629
|
+
var brandCommand = defineCommand95({
|
|
22110
22630
|
meta: {
|
|
22111
22631
|
name: "brand",
|
|
22112
22632
|
description: `Brand asset verification for src/brand/.
|
|
@@ -22122,11 +22642,11 @@ Subcommands:
|
|
|
22122
22642
|
});
|
|
22123
22643
|
|
|
22124
22644
|
// src/commands/canvas/index.ts
|
|
22125
|
-
import { defineCommand as
|
|
22645
|
+
import { defineCommand as defineCommand106 } from "citty";
|
|
22126
22646
|
|
|
22127
22647
|
// src/commands/canvas/catalog.ts
|
|
22128
|
-
import { defineCommand as
|
|
22129
|
-
var catalogCommand =
|
|
22648
|
+
import { defineCommand as defineCommand96 } from "citty";
|
|
22649
|
+
var catalogCommand = defineCommand96({
|
|
22130
22650
|
meta: {
|
|
22131
22651
|
name: "catalog",
|
|
22132
22652
|
description: "Print the agent-facing node catalog (JSON Schema). Includes every registered node grouped by category."
|
|
@@ -22141,7 +22661,7 @@ var catalogCommand = defineCommand95({
|
|
|
22141
22661
|
// src/commands/canvas/critique.ts
|
|
22142
22662
|
import { readFile as readFile3 } from "fs/promises";
|
|
22143
22663
|
import path3 from "path";
|
|
22144
|
-
import { defineCommand as
|
|
22664
|
+
import { defineCommand as defineCommand97 } from "citty";
|
|
22145
22665
|
|
|
22146
22666
|
// src/engine/scaffold/lib/critique.ts
|
|
22147
22667
|
var VIBE_CUE = /\b(light|lighting|golden|moody|warm|cool|tone|grade|contrast|shadow|glow|rim|backlit|neon|soft)\b/i;
|
|
@@ -22261,7 +22781,7 @@ function critiqueCanvas(canvas) {
|
|
|
22261
22781
|
}
|
|
22262
22782
|
|
|
22263
22783
|
// src/commands/canvas/critique.ts
|
|
22264
|
-
var critiqueCommand =
|
|
22784
|
+
var critiqueCommand = defineCommand97({
|
|
22265
22785
|
meta: {
|
|
22266
22786
|
name: "critique",
|
|
22267
22787
|
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."
|
|
@@ -22303,9 +22823,9 @@ import { execFile } from "child_process";
|
|
|
22303
22823
|
import { readdir as readdir2, readFile as readFile4, stat } from "fs/promises";
|
|
22304
22824
|
import path4 from "path";
|
|
22305
22825
|
import { promisify } from "util";
|
|
22306
|
-
import { defineCommand as
|
|
22826
|
+
import { defineCommand as defineCommand98 } from "citty";
|
|
22307
22827
|
var execFileAsync = promisify(execFile);
|
|
22308
|
-
var inspectCommand =
|
|
22828
|
+
var inspectCommand = defineCommand98({
|
|
22309
22829
|
meta: {
|
|
22310
22830
|
name: "inspect",
|
|
22311
22831
|
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."
|
|
@@ -22413,12 +22933,12 @@ async function probeDuration(filePath) {
|
|
|
22413
22933
|
|
|
22414
22934
|
// src/commands/canvas/rerun.ts
|
|
22415
22935
|
import path16 from "path";
|
|
22416
|
-
import { defineCommand as
|
|
22936
|
+
import { defineCommand as defineCommand100 } from "citty";
|
|
22417
22937
|
|
|
22418
22938
|
// src/commands/canvas/run.ts
|
|
22419
22939
|
import { readFile as readFile11 } from "fs/promises";
|
|
22420
22940
|
import path15 from "path";
|
|
22421
|
-
import { defineCommand as
|
|
22941
|
+
import { defineCommand as defineCommand99 } from "citty";
|
|
22422
22942
|
|
|
22423
22943
|
// src/commands/canvas/normalize-paths.ts
|
|
22424
22944
|
import { existsSync as existsSync3, realpathSync } from "fs";
|
|
@@ -26669,7 +27189,7 @@ async function restoreRunSnapshot(manifest, targetDir, opts = {}) {
|
|
|
26669
27189
|
}
|
|
26670
27190
|
|
|
26671
27191
|
// src/commands/canvas/run.ts
|
|
26672
|
-
var runCommand =
|
|
27192
|
+
var runCommand = defineCommand99({
|
|
26673
27193
|
meta: { name: "run", description: "Validate and execute a canvas JSON file." },
|
|
26674
27194
|
args: {
|
|
26675
27195
|
file: { type: "positional", required: true, description: "Path to canvas JSON" },
|
|
@@ -27049,7 +27569,7 @@ async function postInitialRunRecord(client, payload) {
|
|
|
27049
27569
|
|
|
27050
27570
|
// src/commands/canvas/rerun.ts
|
|
27051
27571
|
var SLUG_PATTERN = /^[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/;
|
|
27052
|
-
var rerunCommand =
|
|
27572
|
+
var rerunCommand = defineCommand100({
|
|
27053
27573
|
meta: {
|
|
27054
27574
|
name: "rerun",
|
|
27055
27575
|
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."
|
|
@@ -27146,7 +27666,7 @@ async function fetchManifest(url) {
|
|
|
27146
27666
|
// src/commands/canvas/scaffold-static-ad.ts
|
|
27147
27667
|
import { access, mkdir as mkdir6, readFile as readFile13, writeFile as writeFile8 } from "fs/promises";
|
|
27148
27668
|
import path20 from "path";
|
|
27149
|
-
import { defineCommand as
|
|
27669
|
+
import { defineCommand as defineCommand102 } from "citty";
|
|
27150
27670
|
|
|
27151
27671
|
// src/engine/scaffold/staticAd.ts
|
|
27152
27672
|
import { z as z26 } from "zod";
|
|
@@ -27496,7 +28016,7 @@ function isValidScaffoldSlug(slug) {
|
|
|
27496
28016
|
// src/commands/canvas/sync-definition.ts
|
|
27497
28017
|
import { readdir as readdir6, readFile as readFile12, stat as stat3 } from "fs/promises";
|
|
27498
28018
|
import path19 from "path";
|
|
27499
|
-
import { defineCommand as
|
|
28019
|
+
import { defineCommand as defineCommand101 } from "citty";
|
|
27500
28020
|
|
|
27501
28021
|
// src/commands/canvas/definition-graph.ts
|
|
27502
28022
|
var MAX_NODES = 300;
|
|
@@ -27609,7 +28129,7 @@ async function resolveCanvasPath(inputPath) {
|
|
|
27609
28129
|
const chosen = (slug ? canvases.find((name) => name === `${slug}.canvas.json`) : void 0) ?? canvases[0];
|
|
27610
28130
|
return chosen ? path19.join(dir, chosen) : null;
|
|
27611
28131
|
}
|
|
27612
|
-
var syncDefinitionCommand =
|
|
28132
|
+
var syncDefinitionCommand = defineCommand101({
|
|
27613
28133
|
meta: {
|
|
27614
28134
|
name: "sync-definition",
|
|
27615
28135
|
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."
|
|
@@ -27839,7 +28359,7 @@ async function runVisionPasses(canvas) {
|
|
|
27839
28359
|
return fail3("read_outputs", e instanceof Error ? e.message : String(e));
|
|
27840
28360
|
}
|
|
27841
28361
|
}
|
|
27842
|
-
var scaffoldStaticAdCommand =
|
|
28362
|
+
var scaffoldStaticAdCommand = defineCommand102({
|
|
27843
28363
|
meta: {
|
|
27844
28364
|
name: "scaffold-static-ad",
|
|
27845
28365
|
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."
|
|
@@ -28028,7 +28548,7 @@ var scaffoldStaticAdCommand = defineCommand101({
|
|
|
28028
28548
|
import { access as access2, cp, mkdir as mkdir7, readFile as readFile16, rm as rm6, writeFile as writeFile9 } from "fs/promises";
|
|
28029
28549
|
import { tmpdir as tmpdir2 } from "os";
|
|
28030
28550
|
import path23 from "path";
|
|
28031
|
-
import { defineCommand as
|
|
28551
|
+
import { defineCommand as defineCommand103 } from "citty";
|
|
28032
28552
|
|
|
28033
28553
|
// src/engine/scaffold/lib/model-router.ts
|
|
28034
28554
|
var SEEDANCE = "bytedance/seedance-2.0";
|
|
@@ -28489,7 +29009,7 @@ async function runAnalysisPasses(deconstructCanvas, selectModel) {
|
|
|
28489
29009
|
return fail4("deconstruct", e instanceof Error ? e.message : String(e));
|
|
28490
29010
|
}
|
|
28491
29011
|
}
|
|
28492
|
-
var scaffoldVideoCommand =
|
|
29012
|
+
var scaffoldVideoCommand = defineCommand103({
|
|
28493
29013
|
meta: {
|
|
28494
29014
|
name: "scaffold-video",
|
|
28495
29015
|
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`."
|
|
@@ -28799,7 +29319,7 @@ var scaffoldVideoCommand = defineCommand102({
|
|
|
28799
29319
|
// src/commands/canvas/set-prompt.ts
|
|
28800
29320
|
import { readFile as readFile17, writeFile as writeFile10 } from "fs/promises";
|
|
28801
29321
|
import path24 from "path";
|
|
28802
|
-
import { defineCommand as
|
|
29322
|
+
import { defineCommand as defineCommand104 } from "citty";
|
|
28803
29323
|
function setNodePrompt(canvas, nodeId, text2) {
|
|
28804
29324
|
const nodes = canvas?.nodes;
|
|
28805
29325
|
if (!Array.isArray(nodes)) throw new Error("canvas has no nodes array");
|
|
@@ -28814,7 +29334,7 @@ function setNodePrompt(canvas, nodeId, text2) {
|
|
|
28814
29334
|
newNodes[idx] = newNode;
|
|
28815
29335
|
return { ...canvas, nodes: newNodes };
|
|
28816
29336
|
}
|
|
28817
|
-
var setPromptCommand =
|
|
29337
|
+
var setPromptCommand = defineCommand104({
|
|
28818
29338
|
meta: {
|
|
28819
29339
|
name: "set-prompt",
|
|
28820
29340
|
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."
|
|
@@ -28874,8 +29394,8 @@ var setPromptCommand = defineCommand103({
|
|
|
28874
29394
|
// src/commands/canvas/validate.ts
|
|
28875
29395
|
import { readFile as readFile18 } from "fs/promises";
|
|
28876
29396
|
import path25 from "path";
|
|
28877
|
-
import { defineCommand as
|
|
28878
|
-
var validateCommand =
|
|
29397
|
+
import { defineCommand as defineCommand105 } from "citty";
|
|
29398
|
+
var validateCommand = defineCommand105({
|
|
28879
29399
|
meta: {
|
|
28880
29400
|
name: "validate",
|
|
28881
29401
|
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)."
|
|
@@ -28948,7 +29468,7 @@ var validateCommand = defineCommand104({
|
|
|
28948
29468
|
});
|
|
28949
29469
|
|
|
28950
29470
|
// src/commands/canvas/index.ts
|
|
28951
|
-
var canvasCommand =
|
|
29471
|
+
var canvasCommand = defineCommand106({
|
|
28952
29472
|
meta: {
|
|
28953
29473
|
name: "canvas",
|
|
28954
29474
|
description: `Run Baker creative canvas JSON files locally. Local nodes execute in-process; remote nodes POST to the Convex backend gateway.
|
|
@@ -28982,7 +29502,7 @@ Full guide: __tooling__/docs/tools/baker/canvas.md`
|
|
|
28982
29502
|
});
|
|
28983
29503
|
|
|
28984
29504
|
// src/commands/capabilities/index.ts
|
|
28985
|
-
import { defineCommand as
|
|
29505
|
+
import { defineCommand as defineCommand107 } from "citty";
|
|
28986
29506
|
registerSchema({
|
|
28987
29507
|
command: "capabilities",
|
|
28988
29508
|
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.",
|
|
@@ -29025,7 +29545,7 @@ function capabilityHints(surfaces) {
|
|
|
29025
29545
|
}
|
|
29026
29546
|
return hints;
|
|
29027
29547
|
}
|
|
29028
|
-
var runCapabilities =
|
|
29548
|
+
var runCapabilities = defineCommand107({
|
|
29029
29549
|
meta: {
|
|
29030
29550
|
name: "capabilities",
|
|
29031
29551
|
description: `What Baker can and cannot do for this company, before any work starts.
|
|
@@ -29081,7 +29601,7 @@ Full guide: __tooling__/docs/tools/baker/capabilities.md`
|
|
|
29081
29601
|
var capabilitiesCommand = runCapabilities;
|
|
29082
29602
|
|
|
29083
29603
|
// src/commands/chats/index.ts
|
|
29084
|
-
import { defineCommand as
|
|
29604
|
+
import { defineCommand as defineCommand108 } from "citty";
|
|
29085
29605
|
var STATUS_GROUPS = ["active", "archived", "all"];
|
|
29086
29606
|
var REPO_SURFACES = ["knowledge", "company", "brand", "landings", "flows", "creatives"];
|
|
29087
29607
|
function parseBoundedInt(raw, name, min, max) {
|
|
@@ -29103,7 +29623,7 @@ registerSchema({
|
|
|
29103
29623
|
full: { type: "boolean", description: "Include each Session's full change list", required: false, default: false }
|
|
29104
29624
|
}
|
|
29105
29625
|
});
|
|
29106
|
-
var listCommand11 =
|
|
29626
|
+
var listCommand11 = defineCommand108({
|
|
29107
29627
|
meta: { name: "list", description: "List other Sessions on this account, newest first." },
|
|
29108
29628
|
args: {
|
|
29109
29629
|
status: { type: "string", description: "Filter: active|archived|all (default: all)", required: false },
|
|
@@ -29158,7 +29678,7 @@ registerSchema({
|
|
|
29158
29678
|
}
|
|
29159
29679
|
}
|
|
29160
29680
|
});
|
|
29161
|
-
var viewCommand =
|
|
29681
|
+
var viewCommand = defineCommand108({
|
|
29162
29682
|
meta: {
|
|
29163
29683
|
name: "view",
|
|
29164
29684
|
description: "Inspect one Session's full effects \u2014 git content + actions/tags/ads, kickoff, commits."
|
|
@@ -29202,7 +29722,7 @@ registerSchema({
|
|
|
29202
29722
|
}
|
|
29203
29723
|
}
|
|
29204
29724
|
});
|
|
29205
|
-
var transcriptCommand =
|
|
29725
|
+
var transcriptCommand = defineCommand108({
|
|
29206
29726
|
meta: { name: "transcript", description: "Read another Session's conversation." },
|
|
29207
29727
|
args: {
|
|
29208
29728
|
id: { type: "positional", description: "The Session id", required: true },
|
|
@@ -29254,7 +29774,7 @@ registerSchema({
|
|
|
29254
29774
|
}
|
|
29255
29775
|
}
|
|
29256
29776
|
});
|
|
29257
|
-
var diffCommand =
|
|
29777
|
+
var diffCommand = defineCommand108({
|
|
29258
29778
|
meta: { name: "diff", description: "See a published Session's real file-level changes." },
|
|
29259
29779
|
args: {
|
|
29260
29780
|
id: { type: "positional", description: "The Session id", required: true },
|
|
@@ -29298,7 +29818,7 @@ var diffCommand = defineCommand107({
|
|
|
29298
29818
|
}
|
|
29299
29819
|
}
|
|
29300
29820
|
});
|
|
29301
|
-
var chatsCommand =
|
|
29821
|
+
var chatsCommand = defineCommand108({
|
|
29302
29822
|
meta: {
|
|
29303
29823
|
name: "chats",
|
|
29304
29824
|
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.
|
|
@@ -29313,10 +29833,10 @@ Full guide: __tooling__/docs/tools/baker/chats.md`
|
|
|
29313
29833
|
});
|
|
29314
29834
|
|
|
29315
29835
|
// src/commands/creatives/index.ts
|
|
29316
|
-
import { defineCommand as
|
|
29836
|
+
import { defineCommand as defineCommand110 } from "citty";
|
|
29317
29837
|
|
|
29318
29838
|
// src/commands/creatives/publish.ts
|
|
29319
|
-
import { defineCommand as
|
|
29839
|
+
import { defineCommand as defineCommand109 } from "citty";
|
|
29320
29840
|
|
|
29321
29841
|
// src/commands/images/api.ts
|
|
29322
29842
|
import { readFile as readFile19 } from "fs/promises";
|
|
@@ -29463,7 +29983,7 @@ async function publishCreative(args, deps = defaultImageApiDeps) {
|
|
|
29463
29983
|
chatId: chatIdFromEnv2()
|
|
29464
29984
|
});
|
|
29465
29985
|
}
|
|
29466
|
-
var publishCommand =
|
|
29986
|
+
var publishCommand = defineCommand109({
|
|
29467
29987
|
meta: {
|
|
29468
29988
|
name: "publish",
|
|
29469
29989
|
description: "Publish a final static creative image to Baker Creatives and print the creative reference JSON."
|
|
@@ -29521,7 +30041,7 @@ var publishCommand = defineCommand108({
|
|
|
29521
30041
|
});
|
|
29522
30042
|
|
|
29523
30043
|
// src/commands/creatives/index.ts
|
|
29524
|
-
var creativesCommand3 =
|
|
30044
|
+
var creativesCommand3 = defineCommand110({
|
|
29525
30045
|
meta: {
|
|
29526
30046
|
name: "creatives",
|
|
29527
30047
|
description: `Publish static ad creatives as first-class Baker outputs.
|
|
@@ -29538,7 +30058,7 @@ Full guide: __tooling__/docs/tools/baker/creatives.md`
|
|
|
29538
30058
|
});
|
|
29539
30059
|
|
|
29540
30060
|
// src/commands/flows/index.ts
|
|
29541
|
-
import { defineCommand as
|
|
30061
|
+
import { defineCommand as defineCommand111 } from "citty";
|
|
29542
30062
|
|
|
29543
30063
|
// src/commands/flows/shared.ts
|
|
29544
30064
|
import { existsSync as existsSync5, readdirSync as readdirSync2, readFileSync as readFileSync9 } from "fs";
|
|
@@ -29693,7 +30213,7 @@ function displayName(slug) {
|
|
|
29693
30213
|
const name = tree.displayName;
|
|
29694
30214
|
return typeof name === "string" && name.trim() ? name.trim() : slug;
|
|
29695
30215
|
}
|
|
29696
|
-
var listCommand12 =
|
|
30216
|
+
var listCommand12 = defineCommand111({
|
|
29697
30217
|
meta: {
|
|
29698
30218
|
name: "list",
|
|
29699
30219
|
description: "List Forms in this workspace with the count of confidential fields still needing setup. Example: baker flows list"
|
|
@@ -29707,7 +30227,7 @@ var listCommand12 = defineCommand110({
|
|
|
29707
30227
|
writeJson({ ok: true, data: { flows } });
|
|
29708
30228
|
}
|
|
29709
30229
|
});
|
|
29710
|
-
var showCommand3 =
|
|
30230
|
+
var showCommand3 = defineCommand111({
|
|
29711
30231
|
meta: {
|
|
29712
30232
|
name: "show",
|
|
29713
30233
|
description: "Show a Form's confidential fields and their configuration status (never secret values). Example: baker flows show contact"
|
|
@@ -29728,7 +30248,7 @@ var showCommand3 = defineCommand110({
|
|
|
29728
30248
|
writeJson({ ok: true, data: response });
|
|
29729
30249
|
}
|
|
29730
30250
|
});
|
|
29731
|
-
var flowsCommand =
|
|
30251
|
+
var flowsCommand = defineCommand111({
|
|
29732
30252
|
meta: {
|
|
29733
30253
|
name: "flows",
|
|
29734
30254
|
description: `Read this workspace's Forms (flows) and the configuration status of their confidential fields \u2014 connection secrets, OAuth connections, and third-party field definitions (HubSpot, Calendly, HighLevel, SavvyCal).
|
|
@@ -29752,10 +30272,10 @@ Full guide: __tooling__/docs/tools/baker/flows.md`
|
|
|
29752
30272
|
});
|
|
29753
30273
|
|
|
29754
30274
|
// src/commands/ga4/index.ts
|
|
29755
|
-
import { defineCommand as
|
|
30275
|
+
import { defineCommand as defineCommand118 } from "citty";
|
|
29756
30276
|
|
|
29757
30277
|
// src/commands/ga4/audit.ts
|
|
29758
|
-
import { defineCommand as
|
|
30278
|
+
import { defineCommand as defineCommand112 } from "citty";
|
|
29759
30279
|
|
|
29760
30280
|
// src/commands/ga4/resolve.ts
|
|
29761
30281
|
async function fetchProperties(useCache = true) {
|
|
@@ -29821,7 +30341,7 @@ registerSchema({
|
|
|
29821
30341
|
"no-cache": { type: "boolean", description: "Skip cache, hit API directly", required: false }
|
|
29822
30342
|
}
|
|
29823
30343
|
});
|
|
29824
|
-
var auditCommand2 =
|
|
30344
|
+
var auditCommand2 = defineCommand112({
|
|
29825
30345
|
meta: {
|
|
29826
30346
|
name: "audit",
|
|
29827
30347
|
description: `Run all GA4 admin health checks. Returns property config with playbook warnings.
|
|
@@ -29876,7 +30396,7 @@ Examples:
|
|
|
29876
30396
|
});
|
|
29877
30397
|
|
|
29878
30398
|
// src/commands/ga4/config.ts
|
|
29879
|
-
import { defineCommand as
|
|
30399
|
+
import { defineCommand as defineCommand113 } from "citty";
|
|
29880
30400
|
|
|
29881
30401
|
// src/commands/ga4/shared.ts
|
|
29882
30402
|
import { readFileSync as readFileSync10 } from "fs";
|
|
@@ -29927,7 +30447,7 @@ function loadJsonPayloads(args) {
|
|
|
29927
30447
|
return parsed.map((entry, index) => asObject(entry, "json", index));
|
|
29928
30448
|
}
|
|
29929
30449
|
var RETRYABLE_CODES = /* @__PURE__ */ new Set(["RATE_LIMITED", "INTERNAL_ERROR", "NETWORK_ERROR", "TIMEOUT"]);
|
|
29930
|
-
function
|
|
30450
|
+
function handleError2(err) {
|
|
29931
30451
|
if (err instanceof ApiError) {
|
|
29932
30452
|
const readOnly = err.code === "FORBIDDEN" && /read the property but not change it/i.test(err.message);
|
|
29933
30453
|
writeJsonEnvelope({
|
|
@@ -29968,7 +30488,7 @@ async function stageOp3(op) {
|
|
|
29968
30488
|
hints: [...STAGE_HINTS, ...data.warnings.length > 0 ? [WARNING_HINT] : []]
|
|
29969
30489
|
});
|
|
29970
30490
|
} catch (err) {
|
|
29971
|
-
|
|
30491
|
+
handleError2(err);
|
|
29972
30492
|
}
|
|
29973
30493
|
}
|
|
29974
30494
|
async function stageOps(ops) {
|
|
@@ -29986,7 +30506,7 @@ async function stageOps(ops) {
|
|
|
29986
30506
|
hints: [...STAGE_HINTS, ...data.ops.some((op) => op.warnings.length > 0) ? [WARNING_HINT] : []]
|
|
29987
30507
|
});
|
|
29988
30508
|
} catch (err) {
|
|
29989
|
-
|
|
30509
|
+
handleError2(err);
|
|
29990
30510
|
}
|
|
29991
30511
|
}
|
|
29992
30512
|
async function draftAction2(path39, body, chat) {
|
|
@@ -29996,7 +30516,7 @@ async function draftAction2(path39, body, chat) {
|
|
|
29996
30516
|
writeJsonEnvelope({ ok: true, data });
|
|
29997
30517
|
return data;
|
|
29998
30518
|
} catch (err) {
|
|
29999
|
-
|
|
30519
|
+
handleError2(err);
|
|
30000
30520
|
}
|
|
30001
30521
|
}
|
|
30002
30522
|
function renderDraft(response) {
|
|
@@ -30033,7 +30553,7 @@ async function draftList(json, chat) {
|
|
|
30033
30553
|
process.stdout.write(`${renderDraft(data)}
|
|
30034
30554
|
`);
|
|
30035
30555
|
} catch (err) {
|
|
30036
|
-
|
|
30556
|
+
handleError2(err);
|
|
30037
30557
|
}
|
|
30038
30558
|
}
|
|
30039
30559
|
|
|
@@ -30068,7 +30588,7 @@ function configHints(config) {
|
|
|
30068
30588
|
}
|
|
30069
30589
|
return hints;
|
|
30070
30590
|
}
|
|
30071
|
-
var configCommand =
|
|
30591
|
+
var configCommand = defineCommand113({
|
|
30072
30592
|
meta: {
|
|
30073
30593
|
name: "config",
|
|
30074
30594
|
description: `Read how the property is configured to measure \u2014 key events, custom definitions, custom events, retention
|
|
@@ -30090,13 +30610,13 @@ Examples:
|
|
|
30090
30610
|
});
|
|
30091
30611
|
writeJsonEnvelope({ ok: true, data, hints: configHints(data) });
|
|
30092
30612
|
} catch (err) {
|
|
30093
|
-
|
|
30613
|
+
handleError2(err);
|
|
30094
30614
|
}
|
|
30095
30615
|
}
|
|
30096
30616
|
});
|
|
30097
30617
|
|
|
30098
30618
|
// src/commands/ga4/draft.ts
|
|
30099
|
-
import { defineCommand as
|
|
30619
|
+
import { defineCommand as defineCommand114 } from "citty";
|
|
30100
30620
|
registerSchema({
|
|
30101
30621
|
command: "ga4.draft",
|
|
30102
30622
|
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.",
|
|
@@ -30105,13 +30625,13 @@ registerSchema({
|
|
|
30105
30625
|
chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
|
|
30106
30626
|
}
|
|
30107
30627
|
});
|
|
30108
|
-
var draftCommand3 =
|
|
30628
|
+
var draftCommand3 = defineCommand114({
|
|
30109
30629
|
meta: {
|
|
30110
30630
|
name: "draft",
|
|
30111
30631
|
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."
|
|
30112
30632
|
},
|
|
30113
30633
|
subCommands: {
|
|
30114
|
-
list:
|
|
30634
|
+
list: defineCommand114({
|
|
30115
30635
|
meta: { name: "list", description: "Review everything staged on this chat (--json for the raw envelope)" },
|
|
30116
30636
|
args: {
|
|
30117
30637
|
json: { type: "boolean", description: "Print the raw JSON envelope", required: false },
|
|
@@ -30121,7 +30641,7 @@ var draftCommand3 = defineCommand113({
|
|
|
30121
30641
|
await draftList(args.json === true, args.chat);
|
|
30122
30642
|
}
|
|
30123
30643
|
}),
|
|
30124
|
-
show:
|
|
30644
|
+
show: defineCommand114({
|
|
30125
30645
|
meta: {
|
|
30126
30646
|
name: "show",
|
|
30127
30647
|
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)."
|
|
@@ -30138,7 +30658,7 @@ var draftCommand3 = defineCommand113({
|
|
|
30138
30658
|
);
|
|
30139
30659
|
}
|
|
30140
30660
|
}),
|
|
30141
|
-
amend:
|
|
30661
|
+
amend: defineCommand114({
|
|
30142
30662
|
meta: {
|
|
30143
30663
|
name: "amend",
|
|
30144
30664
|
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."
|
|
@@ -30155,7 +30675,7 @@ var draftCommand3 = defineCommand113({
|
|
|
30155
30675
|
});
|
|
30156
30676
|
}
|
|
30157
30677
|
}),
|
|
30158
|
-
remove:
|
|
30678
|
+
remove: defineCommand114({
|
|
30159
30679
|
meta: { name: "remove", description: "Remove one staged change" },
|
|
30160
30680
|
args: { ref: { type: "positional", description: "Staged ref or target id", required: false } },
|
|
30161
30681
|
run: async ({ args }) => {
|
|
@@ -30164,7 +30684,7 @@ var draftCommand3 = defineCommand113({
|
|
|
30164
30684
|
});
|
|
30165
30685
|
}
|
|
30166
30686
|
}),
|
|
30167
|
-
clear:
|
|
30687
|
+
clear: defineCommand114({
|
|
30168
30688
|
meta: { name: "clear", description: "Discard all Google Analytics changes staged on this chat" },
|
|
30169
30689
|
run: async () => {
|
|
30170
30690
|
await draftAction2("/api/ga4/draft/clear", {});
|
|
@@ -30174,7 +30694,7 @@ var draftCommand3 = defineCommand113({
|
|
|
30174
30694
|
});
|
|
30175
30695
|
|
|
30176
30696
|
// src/commands/ga4/properties.ts
|
|
30177
|
-
import { defineCommand as
|
|
30697
|
+
import { defineCommand as defineCommand115 } from "citty";
|
|
30178
30698
|
registerSchema({
|
|
30179
30699
|
command: "ga4.properties",
|
|
30180
30700
|
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.",
|
|
@@ -30190,7 +30710,7 @@ function propertyHints(properties) {
|
|
|
30190
30710
|
resources: properties.map((property) => ({ id: property.externalId, label: property.name }))
|
|
30191
30711
|
});
|
|
30192
30712
|
}
|
|
30193
|
-
var propertiesCommand =
|
|
30713
|
+
var propertiesCommand = defineCommand115({
|
|
30194
30714
|
meta: {
|
|
30195
30715
|
name: "properties",
|
|
30196
30716
|
description: `List accessible GA4 properties.
|
|
@@ -30240,7 +30760,7 @@ Examples:
|
|
|
30240
30760
|
// src/commands/ga4/query.ts
|
|
30241
30761
|
import { appendFileSync as appendFileSync2, existsSync as existsSync6, readFileSync as readFileSync11, writeFileSync as writeFileSync3 } from "fs";
|
|
30242
30762
|
import { resolve as resolve2 } from "path";
|
|
30243
|
-
import { defineCommand as
|
|
30763
|
+
import { defineCommand as defineCommand116 } from "citty";
|
|
30244
30764
|
|
|
30245
30765
|
// src/commands/ga4/presets.ts
|
|
30246
30766
|
var GA4_PRESETS = [
|
|
@@ -30361,7 +30881,7 @@ function buildRequestBody(args, propertyId, useCache) {
|
|
|
30361
30881
|
if (!useCache) body.skipCache = true;
|
|
30362
30882
|
return body;
|
|
30363
30883
|
}
|
|
30364
|
-
function
|
|
30884
|
+
function handleError3(err) {
|
|
30365
30885
|
if (err instanceof ApiError) {
|
|
30366
30886
|
if (isNotConnectedError(err.code, err.message)) {
|
|
30367
30887
|
handleConnectionError("ga4", err.message);
|
|
@@ -30375,7 +30895,7 @@ function handleError2(err) {
|
|
|
30375
30895
|
});
|
|
30376
30896
|
process.exit(1);
|
|
30377
30897
|
}
|
|
30378
|
-
var queryCommand2 =
|
|
30898
|
+
var queryCommand2 = defineCommand116({
|
|
30379
30899
|
meta: {
|
|
30380
30900
|
name: "query",
|
|
30381
30901
|
description: `Run GA4 Data API reports. Preset-first with free-form escape hatch.
|
|
@@ -30440,13 +30960,13 @@ Free-form (escape hatch):
|
|
|
30440
30960
|
}
|
|
30441
30961
|
outputRows(response.data ?? [], args, response, false);
|
|
30442
30962
|
} catch (err) {
|
|
30443
|
-
|
|
30963
|
+
handleError3(err);
|
|
30444
30964
|
}
|
|
30445
30965
|
}
|
|
30446
30966
|
});
|
|
30447
30967
|
|
|
30448
30968
|
// src/commands/ga4/write-commands.ts
|
|
30449
|
-
import { defineCommand as
|
|
30969
|
+
import { defineCommand as defineCommand117 } from "citty";
|
|
30450
30970
|
var PROPERTY_ARG_DESCRIPTION = "GA4 property id (optional only when one property is connected \u2014 run `baker ga4 properties`)";
|
|
30451
30971
|
var propertyArg = { type: "string", description: PROPERTY_ARG_DESCRIPTION, required: false };
|
|
30452
30972
|
function createJsonDescription(noun) {
|
|
@@ -30464,7 +30984,7 @@ registerSchema({
|
|
|
30464
30984
|
"property-id": { type: "string", description: PROPERTY_ARG_DESCRIPTION, required: false }
|
|
30465
30985
|
}
|
|
30466
30986
|
});
|
|
30467
|
-
var keyEventCommand =
|
|
30987
|
+
var keyEventCommand = defineCommand117({
|
|
30468
30988
|
meta: {
|
|
30469
30989
|
name: "key-event",
|
|
30470
30990
|
description: `Stage key-event (conversion) changes
|
|
@@ -30477,7 +30997,7 @@ Examples:
|
|
|
30477
30997
|
baker ga4 key-event delete 4185`
|
|
30478
30998
|
},
|
|
30479
30999
|
subCommands: {
|
|
30480
|
-
create:
|
|
31000
|
+
create: defineCommand117({
|
|
30481
31001
|
meta: {
|
|
30482
31002
|
name: "create",
|
|
30483
31003
|
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."
|
|
@@ -30498,7 +31018,7 @@ Examples:
|
|
|
30498
31018
|
);
|
|
30499
31019
|
}
|
|
30500
31020
|
}),
|
|
30501
|
-
update:
|
|
31021
|
+
update: defineCommand117({
|
|
30502
31022
|
meta: {
|
|
30503
31023
|
name: "update",
|
|
30504
31024
|
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."
|
|
@@ -30518,7 +31038,7 @@ Examples:
|
|
|
30518
31038
|
});
|
|
30519
31039
|
}
|
|
30520
31040
|
}),
|
|
30521
|
-
delete:
|
|
31041
|
+
delete: defineCommand117({
|
|
30522
31042
|
meta: {
|
|
30523
31043
|
name: "delete",
|
|
30524
31044
|
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."
|
|
@@ -30566,7 +31086,7 @@ for (const { kind, noun, createHint } of DEFINITIONS) {
|
|
|
30566
31086
|
}
|
|
30567
31087
|
function definitionCommand(definition) {
|
|
30568
31088
|
const { command, kind, noun, example } = definition;
|
|
30569
|
-
return
|
|
31089
|
+
return defineCommand117({
|
|
30570
31090
|
meta: {
|
|
30571
31091
|
name: command,
|
|
30572
31092
|
description: `Stage ${noun} changes
|
|
@@ -30578,7 +31098,7 @@ Examples:
|
|
|
30578
31098
|
baker ga4 ${command} archive 12`
|
|
30579
31099
|
},
|
|
30580
31100
|
subCommands: {
|
|
30581
|
-
create:
|
|
31101
|
+
create: defineCommand117({
|
|
30582
31102
|
meta: { name: "create", description: `Stage a new ${noun} (or a JSON array of them, staged together)` },
|
|
30583
31103
|
args: {
|
|
30584
31104
|
json: { type: "string", description: createJsonDescription(noun), required: false },
|
|
@@ -30596,7 +31116,7 @@ Examples:
|
|
|
30596
31116
|
);
|
|
30597
31117
|
}
|
|
30598
31118
|
}),
|
|
30599
|
-
update:
|
|
31119
|
+
update: defineCommand117({
|
|
30600
31120
|
meta: {
|
|
30601
31121
|
name: "update",
|
|
30602
31122
|
description: `Stage a change to an existing ${noun} (pass its id). The parameter name and scope cannot change \u2014 archive and recreate for that.`
|
|
@@ -30616,7 +31136,7 @@ Examples:
|
|
|
30616
31136
|
});
|
|
30617
31137
|
}
|
|
30618
31138
|
}),
|
|
30619
|
-
archive:
|
|
31139
|
+
archive: defineCommand117({
|
|
30620
31140
|
meta: {
|
|
30621
31141
|
name: "archive",
|
|
30622
31142
|
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.`
|
|
@@ -30661,7 +31181,7 @@ var dataStreamArg = {
|
|
|
30661
31181
|
function withStream(args) {
|
|
30662
31182
|
return typeof args["data-stream"] === "string" ? { dataStream: args["data-stream"] } : {};
|
|
30663
31183
|
}
|
|
30664
|
-
var customEventCommand =
|
|
31184
|
+
var customEventCommand = defineCommand117({
|
|
30665
31185
|
meta: {
|
|
30666
31186
|
name: "custom-event",
|
|
30667
31187
|
description: `Stage custom events \u2014 new events built from events the site already sends
|
|
@@ -30672,7 +31192,7 @@ Examples:
|
|
|
30672
31192
|
baker ga4 custom-event delete 7`
|
|
30673
31193
|
},
|
|
30674
31194
|
subCommands: {
|
|
30675
|
-
create:
|
|
31195
|
+
create: defineCommand117({
|
|
30676
31196
|
meta: {
|
|
30677
31197
|
name: "create",
|
|
30678
31198
|
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."
|
|
@@ -30695,7 +31215,7 @@ Examples:
|
|
|
30695
31215
|
);
|
|
30696
31216
|
}
|
|
30697
31217
|
}),
|
|
30698
|
-
update:
|
|
31218
|
+
update: defineCommand117({
|
|
30699
31219
|
meta: { name: "update", description: "Stage a change to an existing custom event (pass its id)" },
|
|
30700
31220
|
args: {
|
|
30701
31221
|
id: { type: "positional", description: "Custom event rule id", required: false },
|
|
@@ -30714,7 +31234,7 @@ Examples:
|
|
|
30714
31234
|
});
|
|
30715
31235
|
}
|
|
30716
31236
|
}),
|
|
30717
|
-
delete:
|
|
31237
|
+
delete: defineCommand117({
|
|
30718
31238
|
meta: {
|
|
30719
31239
|
name: "delete",
|
|
30720
31240
|
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."
|
|
@@ -30769,7 +31289,7 @@ function booleanArg(input, flag) {
|
|
|
30769
31289
|
if (input === "false") return false;
|
|
30770
31290
|
return failValidation3(`--${flag} must be true or false`);
|
|
30771
31291
|
}
|
|
30772
|
-
var dataRetentionCommand =
|
|
31292
|
+
var dataRetentionCommand = defineCommand117({
|
|
30773
31293
|
meta: {
|
|
30774
31294
|
name: "data-retention",
|
|
30775
31295
|
description: `Stage a change to how long Google Analytics keeps data
|
|
@@ -30779,7 +31299,7 @@ Examples:
|
|
|
30779
31299
|
baker ga4 data-retention set --event-data 14 --user-data 14 --reset-on-activity true`
|
|
30780
31300
|
},
|
|
30781
31301
|
subCommands: {
|
|
30782
|
-
set:
|
|
31302
|
+
set: defineCommand117({
|
|
30783
31303
|
meta: { name: "set", description: "Stage the retention window (months)" },
|
|
30784
31304
|
args: {
|
|
30785
31305
|
"event-data": { type: "string", description: "2, 14, 26, 38 or 50", required: false },
|
|
@@ -30808,7 +31328,7 @@ Examples:
|
|
|
30808
31328
|
});
|
|
30809
31329
|
|
|
30810
31330
|
// src/commands/ga4/index.ts
|
|
30811
|
-
var ga4Command =
|
|
31331
|
+
var ga4Command = defineCommand118({
|
|
30812
31332
|
meta: {
|
|
30813
31333
|
name: "ga4",
|
|
30814
31334
|
description: `Google Analytics 4. Report on a property, audit its config, and change what it measures.
|
|
@@ -30849,12 +31369,12 @@ Full guide: __tooling__/docs/tools/baker/ga4.md`
|
|
|
30849
31369
|
});
|
|
30850
31370
|
|
|
30851
31371
|
// src/commands/gsc/index.ts
|
|
30852
|
-
import { defineCommand as
|
|
31372
|
+
import { defineCommand as defineCommand122 } from "citty";
|
|
30853
31373
|
|
|
30854
31374
|
// src/commands/gsc/query.ts
|
|
30855
31375
|
import { appendFileSync as appendFileSync3, existsSync as existsSync7, readFileSync as readFileSync12, writeFileSync as writeFileSync4 } from "fs";
|
|
30856
31376
|
import { resolve as resolve3 } from "path";
|
|
30857
|
-
import { defineCommand as
|
|
31377
|
+
import { defineCommand as defineCommand119 } from "citty";
|
|
30858
31378
|
|
|
30859
31379
|
// src/commands/gsc/presets.ts
|
|
30860
31380
|
var GSC_PRESETS = [
|
|
@@ -31034,7 +31554,7 @@ function buildRequestBody2(args, siteUrl, useCache) {
|
|
|
31034
31554
|
if (!useCache) body.skipCache = true;
|
|
31035
31555
|
return body;
|
|
31036
31556
|
}
|
|
31037
|
-
function
|
|
31557
|
+
function handleError4(err) {
|
|
31038
31558
|
if (err instanceof ApiError) {
|
|
31039
31559
|
if (isNotConnectedError(err.code, err.message)) {
|
|
31040
31560
|
handleConnectionError("gsc", err.message);
|
|
@@ -31048,7 +31568,7 @@ function handleError3(err) {
|
|
|
31048
31568
|
});
|
|
31049
31569
|
process.exit(1);
|
|
31050
31570
|
}
|
|
31051
|
-
var queryCommand3 =
|
|
31571
|
+
var queryCommand3 = defineCommand119({
|
|
31052
31572
|
meta: {
|
|
31053
31573
|
name: "query",
|
|
31054
31574
|
description: `Run GSC Search Analytics queries. Preset-first with free-form escape hatch.
|
|
@@ -31120,13 +31640,13 @@ Free-form (escape hatch):
|
|
|
31120
31640
|
}
|
|
31121
31641
|
outputRows2(response.data ?? [], args, response, false);
|
|
31122
31642
|
} catch (err) {
|
|
31123
|
-
|
|
31643
|
+
handleError4(err);
|
|
31124
31644
|
}
|
|
31125
31645
|
}
|
|
31126
31646
|
});
|
|
31127
31647
|
|
|
31128
31648
|
// src/commands/gsc/sitemaps.ts
|
|
31129
|
-
import { defineCommand as
|
|
31649
|
+
import { defineCommand as defineCommand120 } from "citty";
|
|
31130
31650
|
registerSchema({
|
|
31131
31651
|
command: "gsc.sitemaps",
|
|
31132
31652
|
description: "List sitemaps for a Search Console site. Check sitemap health and errors.",
|
|
@@ -31135,7 +31655,7 @@ registerSchema({
|
|
|
31135
31655
|
"no-cache": { type: "boolean", description: "Skip cache, hit API directly", required: false }
|
|
31136
31656
|
}
|
|
31137
31657
|
});
|
|
31138
|
-
var sitemapsCommand =
|
|
31658
|
+
var sitemapsCommand = defineCommand120({
|
|
31139
31659
|
meta: {
|
|
31140
31660
|
name: "sitemaps",
|
|
31141
31661
|
description: `List sitemaps for a site. Check health and errors.
|
|
@@ -31188,7 +31708,7 @@ Examples:
|
|
|
31188
31708
|
});
|
|
31189
31709
|
|
|
31190
31710
|
// src/commands/gsc/sites.ts
|
|
31191
|
-
import { defineCommand as
|
|
31711
|
+
import { defineCommand as defineCommand121 } from "citty";
|
|
31192
31712
|
registerSchema({
|
|
31193
31713
|
command: "gsc.sites",
|
|
31194
31714
|
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.",
|
|
@@ -31204,7 +31724,7 @@ function siteHints(sites) {
|
|
|
31204
31724
|
resources: sites.map((site) => ({ id: site.siteUrl, label: site.permissionLevel }))
|
|
31205
31725
|
});
|
|
31206
31726
|
}
|
|
31207
|
-
var sitesCommand =
|
|
31727
|
+
var sitesCommand = defineCommand121({
|
|
31208
31728
|
meta: {
|
|
31209
31729
|
name: "sites",
|
|
31210
31730
|
description: `List verified Search Console sites.
|
|
@@ -31252,7 +31772,7 @@ Examples:
|
|
|
31252
31772
|
});
|
|
31253
31773
|
|
|
31254
31774
|
// src/commands/gsc/index.ts
|
|
31255
|
-
var gscCommand =
|
|
31775
|
+
var gscCommand = defineCommand122({
|
|
31256
31776
|
meta: {
|
|
31257
31777
|
name: "gsc",
|
|
31258
31778
|
description: `Google Search Console commands. PPC-SEO arbitrage, brand halo analysis, negative keyword discovery.
|
|
@@ -31276,7 +31796,7 @@ Full guide: __tooling__/docs/tools/baker/gsc.md`
|
|
|
31276
31796
|
});
|
|
31277
31797
|
|
|
31278
31798
|
// src/commands/history/index.ts
|
|
31279
|
-
import { defineCommand as
|
|
31799
|
+
import { defineCommand as defineCommand123 } from "citty";
|
|
31280
31800
|
registerSchema({
|
|
31281
31801
|
command: "history.list",
|
|
31282
31802
|
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.",
|
|
@@ -31331,7 +31851,7 @@ function parseBoundedInt2(raw, name, min, max) {
|
|
|
31331
31851
|
}
|
|
31332
31852
|
return value;
|
|
31333
31853
|
}
|
|
31334
|
-
var listCommand13 =
|
|
31854
|
+
var listCommand13 = defineCommand123({
|
|
31335
31855
|
meta: {
|
|
31336
31856
|
name: "list",
|
|
31337
31857
|
description: "List recent account changes (unified audit log), newest first."
|
|
@@ -31377,7 +31897,7 @@ var listCommand13 = defineCommand122({
|
|
|
31377
31897
|
}
|
|
31378
31898
|
}
|
|
31379
31899
|
});
|
|
31380
|
-
var historyCommand =
|
|
31900
|
+
var historyCommand = defineCommand123({
|
|
31381
31901
|
meta: {
|
|
31382
31902
|
name: "history",
|
|
31383
31903
|
description: `Unified account history (audit log): what changed, who did it, and when.
|
|
@@ -31387,7 +31907,7 @@ Full guide: __tooling__/docs/tools/baker/history.md`
|
|
|
31387
31907
|
});
|
|
31388
31908
|
|
|
31389
31909
|
// src/commands/hubspot/index.ts
|
|
31390
|
-
import { defineCommand as
|
|
31910
|
+
import { defineCommand as defineCommand124 } from "citty";
|
|
31391
31911
|
var EMBED_TYPES = ["legacy", "v4", "unknown"];
|
|
31392
31912
|
function failNotConnected(err) {
|
|
31393
31913
|
if (err instanceof ApiError && err.code === "FORBIDDEN" && err.message.includes(HUBSPOT_MISSING_GRANT_MARKER)) {
|
|
@@ -31541,7 +32061,7 @@ registerSchema({
|
|
|
31541
32061
|
}
|
|
31542
32062
|
}
|
|
31543
32063
|
});
|
|
31544
|
-
var formsListCommand =
|
|
32064
|
+
var formsListCommand = defineCommand124({
|
|
31545
32065
|
meta: {
|
|
31546
32066
|
name: "list",
|
|
31547
32067
|
description: "List HubSpot forms with embed type and post-submit action. Example: baker hubspot forms list --redirecting-only"
|
|
@@ -31586,7 +32106,7 @@ var formsListCommand = defineCommand123({
|
|
|
31586
32106
|
}
|
|
31587
32107
|
}
|
|
31588
32108
|
});
|
|
31589
|
-
var formsViewCommand =
|
|
32109
|
+
var formsViewCommand = defineCommand124({
|
|
31590
32110
|
meta: {
|
|
31591
32111
|
name: "view",
|
|
31592
32112
|
description: "Show one HubSpot form's fields and configuration. Example: baker hubspot forms view 1a2b3c"
|
|
@@ -31638,7 +32158,7 @@ var formsViewCommand = defineCommand123({
|
|
|
31638
32158
|
}
|
|
31639
32159
|
}
|
|
31640
32160
|
});
|
|
31641
|
-
var meetingsListCommand =
|
|
32161
|
+
var meetingsListCommand = defineCommand124({
|
|
31642
32162
|
meta: {
|
|
31643
32163
|
name: "list",
|
|
31644
32164
|
description: "List HubSpot meeting links (calendars). Example: baker hubspot meetings list"
|
|
@@ -31680,7 +32200,7 @@ var meetingsListCommand = defineCommand123({
|
|
|
31680
32200
|
}
|
|
31681
32201
|
}
|
|
31682
32202
|
});
|
|
31683
|
-
var meetingsViewCommand =
|
|
32203
|
+
var meetingsViewCommand = defineCommand124({
|
|
31684
32204
|
meta: {
|
|
31685
32205
|
name: "view",
|
|
31686
32206
|
description: "Show one HubSpot meeting link's booking fields. Example: baker hubspot meetings view discovery-call"
|
|
@@ -31724,7 +32244,7 @@ var meetingsViewCommand = defineCommand123({
|
|
|
31724
32244
|
}
|
|
31725
32245
|
}
|
|
31726
32246
|
});
|
|
31727
|
-
var formsSubmissionsCommand =
|
|
32247
|
+
var formsSubmissionsCommand = defineCommand124({
|
|
31728
32248
|
meta: {
|
|
31729
32249
|
name: "submissions",
|
|
31730
32250
|
description: "How many leads a form received, and when. Example: baker hubspot forms submissions <formId> --days 30"
|
|
@@ -31773,7 +32293,7 @@ var formsSubmissionsCommand = defineCommand123({
|
|
|
31773
32293
|
}
|
|
31774
32294
|
}
|
|
31775
32295
|
});
|
|
31776
|
-
var workflowsListCommand =
|
|
32296
|
+
var workflowsListCommand = defineCommand124({
|
|
31777
32297
|
meta: {
|
|
31778
32298
|
name: "list",
|
|
31779
32299
|
description: "List HubSpot workflows. Example: baker hubspot workflows list --enabled-only"
|
|
@@ -31838,7 +32358,7 @@ function workflowViewHints(workflow) {
|
|
|
31838
32358
|
}
|
|
31839
32359
|
return hints;
|
|
31840
32360
|
}
|
|
31841
|
-
var workflowsViewCommand =
|
|
32361
|
+
var workflowsViewCommand = defineCommand124({
|
|
31842
32362
|
meta: {
|
|
31843
32363
|
name: "view",
|
|
31844
32364
|
description: "Read one workflow's real configuration \u2014 enrolment, branches in order, and what each step writes. Example: baker hubspot workflows view 121183594 --full"
|
|
@@ -31865,7 +32385,7 @@ var workflowsViewCommand = defineCommand123({
|
|
|
31865
32385
|
}
|
|
31866
32386
|
}
|
|
31867
32387
|
});
|
|
31868
|
-
var pipelinesListCommand =
|
|
32388
|
+
var pipelinesListCommand = defineCommand124({
|
|
31869
32389
|
meta: {
|
|
31870
32390
|
name: "list",
|
|
31871
32391
|
description: "List HubSpot deal pipelines and their stages. Example: baker hubspot pipelines list"
|
|
@@ -31882,7 +32402,7 @@ var pipelinesListCommand = defineCommand123({
|
|
|
31882
32402
|
}
|
|
31883
32403
|
}
|
|
31884
32404
|
});
|
|
31885
|
-
var contactsSummaryCommand =
|
|
32405
|
+
var contactsSummaryCommand = defineCommand124({
|
|
31886
32406
|
meta: {
|
|
31887
32407
|
name: "summary",
|
|
31888
32408
|
description: "Whether recent leads are being worked, as counts. Example: baker hubspot contacts summary --days 30"
|
|
@@ -31952,7 +32472,7 @@ function contactLookupHints(data) {
|
|
|
31952
32472
|
}
|
|
31953
32473
|
return hints;
|
|
31954
32474
|
}
|
|
31955
|
-
var contactsLookupCommand =
|
|
32475
|
+
var contactsLookupCommand = defineCommand124({
|
|
31956
32476
|
meta: {
|
|
31957
32477
|
name: "lookup",
|
|
31958
32478
|
description: "Find one contact by email and see whether it was worked. Example: baker hubspot contacts lookup a@b.com"
|
|
@@ -31976,27 +32496,27 @@ var contactsLookupCommand = defineCommand123({
|
|
|
31976
32496
|
}
|
|
31977
32497
|
}
|
|
31978
32498
|
});
|
|
31979
|
-
var contactsCommand =
|
|
32499
|
+
var contactsCommand = defineCommand124({
|
|
31980
32500
|
meta: { name: "contacts", description: "Contacts on the connected HubSpot account." },
|
|
31981
32501
|
subCommands: { summary: contactsSummaryCommand, lookup: contactsLookupCommand }
|
|
31982
32502
|
});
|
|
31983
|
-
var formsCommand =
|
|
32503
|
+
var formsCommand = defineCommand124({
|
|
31984
32504
|
meta: { name: "forms", description: "HubSpot forms on the connected account." },
|
|
31985
32505
|
subCommands: { list: formsListCommand, view: formsViewCommand, submissions: formsSubmissionsCommand }
|
|
31986
32506
|
});
|
|
31987
|
-
var workflowsCommand =
|
|
32507
|
+
var workflowsCommand = defineCommand124({
|
|
31988
32508
|
meta: { name: "workflows", description: "HubSpot workflows on the connected account." },
|
|
31989
32509
|
subCommands: { list: workflowsListCommand, view: workflowsViewCommand }
|
|
31990
32510
|
});
|
|
31991
|
-
var pipelinesCommand =
|
|
32511
|
+
var pipelinesCommand = defineCommand124({
|
|
31992
32512
|
meta: { name: "pipelines", description: "HubSpot deal pipelines on the connected account." },
|
|
31993
32513
|
subCommands: { list: pipelinesListCommand }
|
|
31994
32514
|
});
|
|
31995
|
-
var meetingsCommand =
|
|
32515
|
+
var meetingsCommand = defineCommand124({
|
|
31996
32516
|
meta: { name: "meetings", description: "HubSpot meeting links (calendars) on the connected account." },
|
|
31997
32517
|
subCommands: { list: meetingsListCommand, view: meetingsViewCommand }
|
|
31998
32518
|
});
|
|
31999
|
-
var hubspotCommand =
|
|
32519
|
+
var hubspotCommand = defineCommand124({
|
|
32000
32520
|
meta: {
|
|
32001
32521
|
name: "hubspot",
|
|
32002
32522
|
description: `Read the connected HubSpot account \u2014 forms, the leads they received, workflows, deal pipelines and
|
|
@@ -32034,10 +32554,10 @@ Full guide: __tooling__/docs/tools/baker/hubspot.md`
|
|
|
32034
32554
|
});
|
|
32035
32555
|
|
|
32036
32556
|
// src/commands/images/index.ts
|
|
32037
|
-
import { defineCommand as
|
|
32557
|
+
import { defineCommand as defineCommand150 } from "citty";
|
|
32038
32558
|
|
|
32039
32559
|
// src/commands/images/crop.ts
|
|
32040
|
-
import { defineCommand as
|
|
32560
|
+
import { defineCommand as defineCommand125 } from "citty";
|
|
32041
32561
|
|
|
32042
32562
|
// src/lib/image/crop-sprite.ts
|
|
32043
32563
|
import sharp from "sharp";
|
|
@@ -32159,7 +32679,7 @@ function emitError2(err) {
|
|
|
32159
32679
|
}
|
|
32160
32680
|
process.exit(1);
|
|
32161
32681
|
}
|
|
32162
|
-
var cropCommand =
|
|
32682
|
+
var cropCommand = defineCommand125({
|
|
32163
32683
|
meta: {
|
|
32164
32684
|
name: "crop",
|
|
32165
32685
|
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"
|
|
@@ -32195,7 +32715,7 @@ var cropCommand = defineCommand124({
|
|
|
32195
32715
|
});
|
|
32196
32716
|
|
|
32197
32717
|
// src/commands/images/delete.ts
|
|
32198
|
-
import { defineCommand as
|
|
32718
|
+
import { defineCommand as defineCommand126 } from "citty";
|
|
32199
32719
|
registerSchema({
|
|
32200
32720
|
command: "images.delete",
|
|
32201
32721
|
description: "Delete an image by ID",
|
|
@@ -32209,7 +32729,7 @@ registerSchema({
|
|
|
32209
32729
|
}
|
|
32210
32730
|
}
|
|
32211
32731
|
});
|
|
32212
|
-
var deleteCommand2 =
|
|
32732
|
+
var deleteCommand2 = defineCommand126({
|
|
32213
32733
|
meta: {
|
|
32214
32734
|
name: "delete",
|
|
32215
32735
|
description: "Delete an image by ID. Use --dry-run to preview. Example: baker images delete j571abc123 --dry-run"
|
|
@@ -32250,7 +32770,7 @@ var deleteCommand2 = defineCommand125({
|
|
|
32250
32770
|
});
|
|
32251
32771
|
|
|
32252
32772
|
// src/commands/images/dimensions.ts
|
|
32253
|
-
import { defineCommand as
|
|
32773
|
+
import { defineCommand as defineCommand127 } from "citty";
|
|
32254
32774
|
|
|
32255
32775
|
// src/lib/image/dimensions.ts
|
|
32256
32776
|
import { imageSize } from "image-size";
|
|
@@ -32273,7 +32793,7 @@ registerSchema({
|
|
|
32273
32793
|
target: { type: "string", description: "Local file path or remote http(s) URL", required: true }
|
|
32274
32794
|
}
|
|
32275
32795
|
});
|
|
32276
|
-
var dimensionsCommand =
|
|
32796
|
+
var dimensionsCommand = defineCommand127({
|
|
32277
32797
|
meta: {
|
|
32278
32798
|
name: "dimensions",
|
|
32279
32799
|
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"
|
|
@@ -32317,7 +32837,7 @@ var dimensionsCommand = defineCommand126({
|
|
|
32317
32837
|
});
|
|
32318
32838
|
|
|
32319
32839
|
// src/commands/images/download.ts
|
|
32320
|
-
import { defineCommand as
|
|
32840
|
+
import { defineCommand as defineCommand128 } from "citty";
|
|
32321
32841
|
|
|
32322
32842
|
// src/commands/images/downloadPaths.ts
|
|
32323
32843
|
import { basename as basename2, extname as extname3, join as join5 } from "path";
|
|
@@ -32542,7 +33062,7 @@ function emitError3(err) {
|
|
|
32542
33062
|
writeJson({ ok: false, error: { code: "INTERNAL_ERROR", message: "Unexpected error" } });
|
|
32543
33063
|
process.exit(1);
|
|
32544
33064
|
}
|
|
32545
|
-
var downloadCommand =
|
|
33065
|
+
var downloadCommand = defineCommand128({
|
|
32546
33066
|
meta: {
|
|
32547
33067
|
name: "download",
|
|
32548
33068
|
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"
|
|
@@ -32575,7 +33095,7 @@ var downloadCommand = defineCommand127({
|
|
|
32575
33095
|
});
|
|
32576
33096
|
|
|
32577
33097
|
// src/commands/images/extract.ts
|
|
32578
|
-
import { defineCommand as
|
|
33098
|
+
import { defineCommand as defineCommand129 } from "citty";
|
|
32579
33099
|
|
|
32580
33100
|
// src/commands/images/autoIngest.ts
|
|
32581
33101
|
var AUTO_INGEST_MAX = {
|
|
@@ -32622,7 +33142,7 @@ registerSchema({
|
|
|
32622
33142
|
}
|
|
32623
33143
|
}
|
|
32624
33144
|
});
|
|
32625
|
-
var extractCommand =
|
|
33145
|
+
var extractCommand = defineCommand129({
|
|
32626
33146
|
meta: {
|
|
32627
33147
|
name: "extract",
|
|
32628
33148
|
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"
|
|
@@ -32677,7 +33197,7 @@ var extractCommand = defineCommand128({
|
|
|
32677
33197
|
});
|
|
32678
33198
|
|
|
32679
33199
|
// src/commands/images/find.ts
|
|
32680
|
-
import { defineCommand as
|
|
33200
|
+
import { defineCommand as defineCommand130 } from "citty";
|
|
32681
33201
|
|
|
32682
33202
|
// src/commands/images/providerHits.ts
|
|
32683
33203
|
function asRecord3(value) {
|
|
@@ -32815,7 +33335,7 @@ registerSchema({
|
|
|
32815
33335
|
full: { type: "boolean", description: "Include full metadata", required: false, default: false }
|
|
32816
33336
|
}
|
|
32817
33337
|
});
|
|
32818
|
-
var findCommand =
|
|
33338
|
+
var findCommand = defineCommand130({
|
|
32819
33339
|
meta: {
|
|
32820
33340
|
name: "find",
|
|
32821
33341
|
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"
|
|
@@ -32888,7 +33408,7 @@ var findCommand = defineCommand129({
|
|
|
32888
33408
|
});
|
|
32889
33409
|
|
|
32890
33410
|
// src/commands/images/get.ts
|
|
32891
|
-
import { defineCommand as
|
|
33411
|
+
import { defineCommand as defineCommand131 } from "citty";
|
|
32892
33412
|
registerSchema({
|
|
32893
33413
|
command: "images.get",
|
|
32894
33414
|
description: "Get a single image by ID",
|
|
@@ -32896,7 +33416,7 @@ registerSchema({
|
|
|
32896
33416
|
id: { type: "string", description: "Image ID", required: true }
|
|
32897
33417
|
}
|
|
32898
33418
|
});
|
|
32899
|
-
var getCommand3 =
|
|
33419
|
+
var getCommand3 = defineCommand131({
|
|
32900
33420
|
meta: { name: "get", description: "Get a single image by ID. Example: baker images get j571abc123" },
|
|
32901
33421
|
args: {
|
|
32902
33422
|
id: { type: "positional", description: "Image ID", required: false },
|
|
@@ -32932,7 +33452,7 @@ var getCommand3 = defineCommand130({
|
|
|
32932
33452
|
});
|
|
32933
33453
|
|
|
32934
33454
|
// src/commands/images/gif.ts
|
|
32935
|
-
import { defineCommand as
|
|
33455
|
+
import { defineCommand as defineCommand132 } from "citty";
|
|
32936
33456
|
registerSchema({
|
|
32937
33457
|
command: "images.gif",
|
|
32938
33458
|
description: "Search Giphy for GIFs / reaction memes (paid social creative).",
|
|
@@ -32964,7 +33484,7 @@ registerSchema({
|
|
|
32964
33484
|
}
|
|
32965
33485
|
}
|
|
32966
33486
|
});
|
|
32967
|
-
var gifCommand =
|
|
33487
|
+
var gifCommand = defineCommand132({
|
|
32968
33488
|
meta: {
|
|
32969
33489
|
name: "gif",
|
|
32970
33490
|
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"
|
|
@@ -33011,7 +33531,7 @@ var gifCommand = defineCommand131({
|
|
|
33011
33531
|
});
|
|
33012
33532
|
|
|
33013
33533
|
// src/commands/images/google.ts
|
|
33014
|
-
import { defineCommand as
|
|
33534
|
+
import { defineCommand as defineCommand133 } from "citty";
|
|
33015
33535
|
var GOOGLE_ERROR_FIX = {
|
|
33016
33536
|
action: "use_different_resource",
|
|
33017
33537
|
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."
|
|
@@ -33051,7 +33571,7 @@ registerSchema({
|
|
|
33051
33571
|
}
|
|
33052
33572
|
}
|
|
33053
33573
|
});
|
|
33054
|
-
var googleCommand2 =
|
|
33574
|
+
var googleCommand2 = defineCommand133({
|
|
33055
33575
|
meta: {
|
|
33056
33576
|
name: "google",
|
|
33057
33577
|
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"
|
|
@@ -33124,7 +33644,7 @@ var googleCommand2 = defineCommand132({
|
|
|
33124
33644
|
});
|
|
33125
33645
|
|
|
33126
33646
|
// src/commands/images/group.ts
|
|
33127
|
-
import { defineCommand as
|
|
33647
|
+
import { defineCommand as defineCommand134 } from "citty";
|
|
33128
33648
|
|
|
33129
33649
|
// src/commands/mediaGroup.ts
|
|
33130
33650
|
async function runMediaGroupLookup(input) {
|
|
@@ -33177,7 +33697,7 @@ registerSchema({
|
|
|
33177
33697
|
"group-key": { type: "string", description: "The set key directly, when you already have it", required: false }
|
|
33178
33698
|
}
|
|
33179
33699
|
});
|
|
33180
|
-
var groupCommand =
|
|
33700
|
+
var groupCommand = defineCommand134({
|
|
33181
33701
|
meta: {
|
|
33182
33702
|
name: "group",
|
|
33183
33703
|
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>"
|
|
@@ -33197,7 +33717,7 @@ var groupCommand = defineCommand133({
|
|
|
33197
33717
|
});
|
|
33198
33718
|
|
|
33199
33719
|
// src/commands/images/icon.ts
|
|
33200
|
-
import { defineCommand as
|
|
33720
|
+
import { defineCommand as defineCommand135 } from "citty";
|
|
33201
33721
|
|
|
33202
33722
|
// src/commands/images/brandVerification.ts
|
|
33203
33723
|
function brandToken(domain) {
|
|
@@ -33294,7 +33814,7 @@ registerSchema({
|
|
|
33294
33814
|
full: { type: "boolean", description: "Include full metadata", required: false, default: false }
|
|
33295
33815
|
}
|
|
33296
33816
|
});
|
|
33297
|
-
var iconCommand =
|
|
33817
|
+
var iconCommand = defineCommand135({
|
|
33298
33818
|
meta: {
|
|
33299
33819
|
name: "icon",
|
|
33300
33820
|
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'"
|
|
@@ -33364,7 +33884,7 @@ var iconCommand = defineCommand134({
|
|
|
33364
33884
|
});
|
|
33365
33885
|
|
|
33366
33886
|
// src/commands/images/ingest.ts
|
|
33367
|
-
import { defineCommand as
|
|
33887
|
+
import { defineCommand as defineCommand136 } from "citty";
|
|
33368
33888
|
registerSchema({
|
|
33369
33889
|
command: "images.ingest",
|
|
33370
33890
|
description: "Ingest a remote image URL into the library (full describe + embed).",
|
|
@@ -33378,7 +33898,7 @@ registerSchema({
|
|
|
33378
33898
|
fields: { type: "string", description: "Comma-separated field names to include", required: false }
|
|
33379
33899
|
}
|
|
33380
33900
|
});
|
|
33381
|
-
var ingestCommand =
|
|
33901
|
+
var ingestCommand = defineCommand136({
|
|
33382
33902
|
meta: {
|
|
33383
33903
|
name: "ingest",
|
|
33384
33904
|
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"
|
|
@@ -33428,7 +33948,7 @@ var ingestCommand = defineCommand135({
|
|
|
33428
33948
|
});
|
|
33429
33949
|
|
|
33430
33950
|
// src/commands/images/layerize.ts
|
|
33431
|
-
import { defineCommand as
|
|
33951
|
+
import { defineCommand as defineCommand137 } from "citty";
|
|
33432
33952
|
registerSchema({
|
|
33433
33953
|
command: "images.layerize",
|
|
33434
33954
|
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.",
|
|
@@ -33492,7 +34012,7 @@ async function pollUntilSettled(imageId, maxWait) {
|
|
|
33492
34012
|
}
|
|
33493
34013
|
return null;
|
|
33494
34014
|
}
|
|
33495
|
-
var layerizeCommand =
|
|
34015
|
+
var layerizeCommand = defineCommand137({
|
|
33496
34016
|
meta: {
|
|
33497
34017
|
name: "layerize",
|
|
33498
34018
|
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'"
|
|
@@ -33561,7 +34081,7 @@ registerSchema({
|
|
|
33561
34081
|
full: { type: "boolean", description: "Include geometry and typography for every layer", required: false }
|
|
33562
34082
|
}
|
|
33563
34083
|
});
|
|
33564
|
-
var layersCommand =
|
|
34084
|
+
var layersCommand = defineCommand137({
|
|
33565
34085
|
meta: {
|
|
33566
34086
|
name: "layers",
|
|
33567
34087
|
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"
|
|
@@ -33601,7 +34121,7 @@ var layersCommand = defineCommand136({
|
|
|
33601
34121
|
});
|
|
33602
34122
|
|
|
33603
34123
|
// src/commands/images/library.ts
|
|
33604
|
-
import { defineCommand as
|
|
34124
|
+
import { defineCommand as defineCommand138 } from "citty";
|
|
33605
34125
|
registerSchema({
|
|
33606
34126
|
command: "images.library",
|
|
33607
34127
|
description: "Search the company image library. Returns only ready images.",
|
|
@@ -33627,7 +34147,7 @@ registerSchema({
|
|
|
33627
34147
|
}
|
|
33628
34148
|
}
|
|
33629
34149
|
});
|
|
33630
|
-
var libraryCommand =
|
|
34150
|
+
var libraryCommand = defineCommand138({
|
|
33631
34151
|
meta: {
|
|
33632
34152
|
name: "library",
|
|
33633
34153
|
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"
|
|
@@ -33690,7 +34210,7 @@ var libraryCommand = defineCommand137({
|
|
|
33690
34210
|
});
|
|
33691
34211
|
|
|
33692
34212
|
// src/commands/images/logo.ts
|
|
33693
|
-
import { defineCommand as
|
|
34213
|
+
import { defineCommand as defineCommand139 } from "citty";
|
|
33694
34214
|
registerSchema({
|
|
33695
34215
|
command: "images.logo",
|
|
33696
34216
|
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.",
|
|
@@ -33718,7 +34238,7 @@ registerSchema({
|
|
|
33718
34238
|
full: { type: "boolean", description: "Include full metadata", required: false, default: false }
|
|
33719
34239
|
}
|
|
33720
34240
|
});
|
|
33721
|
-
var logoCommand =
|
|
34241
|
+
var logoCommand = defineCommand139({
|
|
33722
34242
|
meta: {
|
|
33723
34243
|
name: "logo",
|
|
33724
34244
|
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"
|
|
@@ -33791,7 +34311,7 @@ var logoCommand = defineCommand138({
|
|
|
33791
34311
|
});
|
|
33792
34312
|
|
|
33793
34313
|
// src/commands/images/normalize.ts
|
|
33794
|
-
import { defineCommand as
|
|
34314
|
+
import { defineCommand as defineCommand140 } from "citty";
|
|
33795
34315
|
|
|
33796
34316
|
// src/lib/image/color-changer.ts
|
|
33797
34317
|
import quantize from "quantize";
|
|
@@ -34523,7 +35043,7 @@ function coerceRawArgs(args) {
|
|
|
34523
35043
|
"dry-run": bool(args["dry-run"])
|
|
34524
35044
|
};
|
|
34525
35045
|
}
|
|
34526
|
-
var normalizeCommand =
|
|
35046
|
+
var normalizeCommand = defineCommand140({
|
|
34527
35047
|
meta: {
|
|
34528
35048
|
name: "normalize",
|
|
34529
35049
|
description: `Normalize logos / images: declarative recolor + bg removal + trim + resize. Operates on local files; writes in-place by default.
|
|
@@ -34578,7 +35098,7 @@ Examples:
|
|
|
34578
35098
|
});
|
|
34579
35099
|
|
|
34580
35100
|
// src/commands/images/pinterest.ts
|
|
34581
|
-
import { defineCommand as
|
|
35101
|
+
import { defineCommand as defineCommand141 } from "citty";
|
|
34582
35102
|
registerSchema({
|
|
34583
35103
|
command: "images.pinterest",
|
|
34584
35104
|
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.",
|
|
@@ -34598,7 +35118,7 @@ registerSchema({
|
|
|
34598
35118
|
}
|
|
34599
35119
|
}
|
|
34600
35120
|
});
|
|
34601
|
-
var pinterestCommand =
|
|
35121
|
+
var pinterestCommand = defineCommand141({
|
|
34602
35122
|
meta: {
|
|
34603
35123
|
name: "pinterest",
|
|
34604
35124
|
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'"
|
|
@@ -34655,7 +35175,7 @@ var pinterestCommand = defineCommand140({
|
|
|
34655
35175
|
});
|
|
34656
35176
|
|
|
34657
35177
|
// src/commands/images/screenshot.ts
|
|
34658
|
-
import { defineCommand as
|
|
35178
|
+
import { defineCommand as defineCommand142 } from "citty";
|
|
34659
35179
|
registerSchema({
|
|
34660
35180
|
command: "images.screenshot",
|
|
34661
35181
|
description: "Capture a website screenshot via ScreenshotOne. Auto-ingests on success.",
|
|
@@ -34674,7 +35194,7 @@ registerSchema({
|
|
|
34674
35194
|
full: { type: "boolean", description: "Include full metadata", required: false, default: false }
|
|
34675
35195
|
}
|
|
34676
35196
|
});
|
|
34677
|
-
var screenshotCommand =
|
|
35197
|
+
var screenshotCommand = defineCommand142({
|
|
34678
35198
|
meta: {
|
|
34679
35199
|
name: "screenshot",
|
|
34680
35200
|
description: "Screenshot a URL via ScreenshotOne. $0.009/capture. Auto-ingests to library.\n\nExample: baker images screenshot https://stripe.com --full-page"
|
|
@@ -34738,7 +35258,7 @@ var screenshotCommand = defineCommand141({
|
|
|
34738
35258
|
});
|
|
34739
35259
|
|
|
34740
35260
|
// src/commands/images/search.ts
|
|
34741
|
-
import { defineCommand as
|
|
35261
|
+
import { defineCommand as defineCommand143 } from "citty";
|
|
34742
35262
|
registerSchema({
|
|
34743
35263
|
command: "images.search",
|
|
34744
35264
|
description: "Search images by text query. Only returns ready images.",
|
|
@@ -34754,7 +35274,7 @@ registerSchema({
|
|
|
34754
35274
|
tags: { type: "string", description: "Comma-separated tags to filter by", required: false }
|
|
34755
35275
|
}
|
|
34756
35276
|
});
|
|
34757
|
-
var searchCommand =
|
|
35277
|
+
var searchCommand = defineCommand143({
|
|
34758
35278
|
meta: {
|
|
34759
35279
|
name: "search",
|
|
34760
35280
|
description: "Semantic search images by text query. Uses hybrid BM25 + vector + reranking. Example: baker images search 'hero banner' --aspect-ratio 16:9 --tags logo"
|
|
@@ -34814,7 +35334,7 @@ var searchCommand = defineCommand142({
|
|
|
34814
35334
|
});
|
|
34815
35335
|
|
|
34816
35336
|
// src/commands/images/sticker.ts
|
|
34817
|
-
import { defineCommand as
|
|
35337
|
+
import { defineCommand as defineCommand144 } from "citty";
|
|
34818
35338
|
registerSchema({
|
|
34819
35339
|
command: "images.sticker",
|
|
34820
35340
|
description: "Search Giphy stickers \u2014 transparent-background overlays for ad creative.",
|
|
@@ -34846,7 +35366,7 @@ registerSchema({
|
|
|
34846
35366
|
}
|
|
34847
35367
|
}
|
|
34848
35368
|
});
|
|
34849
|
-
var stickerCommand =
|
|
35369
|
+
var stickerCommand = defineCommand144({
|
|
34850
35370
|
meta: {
|
|
34851
35371
|
name: "sticker",
|
|
34852
35372
|
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"
|
|
@@ -34893,7 +35413,7 @@ var stickerCommand = defineCommand143({
|
|
|
34893
35413
|
});
|
|
34894
35414
|
|
|
34895
35415
|
// src/commands/images/stock.ts
|
|
34896
|
-
import { defineCommand as
|
|
35416
|
+
import { defineCommand as defineCommand145 } from "citty";
|
|
34897
35417
|
var STOCK_ERROR_FIX = {
|
|
34898
35418
|
action: "use_different_resource",
|
|
34899
35419
|
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."
|
|
@@ -34970,7 +35490,7 @@ function buildStockRequest(query, args) {
|
|
|
34970
35490
|
if (args.context) body.descriptionContext = args.context;
|
|
34971
35491
|
return body;
|
|
34972
35492
|
}
|
|
34973
|
-
var stockCommand =
|
|
35493
|
+
var stockCommand = defineCommand145({
|
|
34974
35494
|
meta: {
|
|
34975
35495
|
name: "stock",
|
|
34976
35496
|
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"
|
|
@@ -35043,7 +35563,7 @@ var stockCommand = defineCommand144({
|
|
|
35043
35563
|
});
|
|
35044
35564
|
|
|
35045
35565
|
// src/lib/tags-command.ts
|
|
35046
|
-
import { defineCommand as
|
|
35566
|
+
import { defineCommand as defineCommand146 } from "citty";
|
|
35047
35567
|
function makeTagsCommand(command, label, endpoint) {
|
|
35048
35568
|
registerSchema({
|
|
35049
35569
|
command: `${command}.tags`,
|
|
@@ -35052,7 +35572,7 @@ function makeTagsCommand(command, label, endpoint) {
|
|
|
35052
35572
|
output: { type: "string", description: "Output format: md|json", required: false, default: "md" }
|
|
35053
35573
|
}
|
|
35054
35574
|
});
|
|
35055
|
-
return
|
|
35575
|
+
return defineCommand146({
|
|
35056
35576
|
meta: {
|
|
35057
35577
|
name: "tags",
|
|
35058
35578
|
description: `List the available ${label} tag names (defaults + company custom tags). Use before filtering with --tags. Example: baker ${command} tags`
|
|
@@ -35085,10 +35605,10 @@ function makeTagsCommand(command, label, endpoint) {
|
|
|
35085
35605
|
}
|
|
35086
35606
|
|
|
35087
35607
|
// src/commands/images/tags.ts
|
|
35088
|
-
var
|
|
35608
|
+
var tagsCommand3 = makeTagsCommand("images", "image", "/api/images/tags");
|
|
35089
35609
|
|
|
35090
35610
|
// src/commands/images/upload.ts
|
|
35091
|
-
import { defineCommand as
|
|
35611
|
+
import { defineCommand as defineCommand147 } from "citty";
|
|
35092
35612
|
registerSchema({
|
|
35093
35613
|
command: "images.upload",
|
|
35094
35614
|
description: "Upload an image to the library \u2014 local file path or remote http(s) URL.",
|
|
@@ -35126,7 +35646,7 @@ registerSchema({
|
|
|
35126
35646
|
function isRemoteUrl2(value) {
|
|
35127
35647
|
return /^https?:\/\//i.test(value);
|
|
35128
35648
|
}
|
|
35129
|
-
var uploadCommand =
|
|
35649
|
+
var uploadCommand = defineCommand147({
|
|
35130
35650
|
meta: {
|
|
35131
35651
|
name: "upload",
|
|
35132
35652
|
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'"
|
|
@@ -35219,7 +35739,7 @@ async function uploadLocal(target, args) {
|
|
|
35219
35739
|
}
|
|
35220
35740
|
|
|
35221
35741
|
// src/commands/images/upscale.ts
|
|
35222
|
-
import { defineCommand as
|
|
35742
|
+
import { defineCommand as defineCommand148 } from "citty";
|
|
35223
35743
|
registerSchema({
|
|
35224
35744
|
command: "images.upscale",
|
|
35225
35745
|
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).",
|
|
@@ -35234,7 +35754,7 @@ registerSchema({
|
|
|
35234
35754
|
}
|
|
35235
35755
|
});
|
|
35236
35756
|
var POLL_INTERVAL_MS4 = 1500;
|
|
35237
|
-
var upscaleCommand =
|
|
35757
|
+
var upscaleCommand = defineCommand148({
|
|
35238
35758
|
meta: {
|
|
35239
35759
|
name: "upscale",
|
|
35240
35760
|
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"
|
|
@@ -35289,7 +35809,7 @@ var upscaleCommand = defineCommand147({
|
|
|
35289
35809
|
});
|
|
35290
35810
|
|
|
35291
35811
|
// src/commands/images/use.ts
|
|
35292
|
-
import { defineCommand as
|
|
35812
|
+
import { defineCommand as defineCommand149 } from "citty";
|
|
35293
35813
|
registerSchema({
|
|
35294
35814
|
command: "images.use",
|
|
35295
35815
|
description: "Ingest a URL and wait for the library record to be ready.",
|
|
@@ -35318,7 +35838,7 @@ function emitReady(ingestResult, doc, args) {
|
|
|
35318
35838
|
args.full === true
|
|
35319
35839
|
);
|
|
35320
35840
|
}
|
|
35321
|
-
var useCommand =
|
|
35841
|
+
var useCommand = defineCommand149({
|
|
35322
35842
|
meta: {
|
|
35323
35843
|
name: "use",
|
|
35324
35844
|
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"
|
|
@@ -35367,7 +35887,7 @@ var useCommand = defineCommand148({
|
|
|
35367
35887
|
});
|
|
35368
35888
|
|
|
35369
35889
|
// src/commands/images/index.ts
|
|
35370
|
-
var imagesCommand =
|
|
35890
|
+
var imagesCommand = defineCommand150({
|
|
35371
35891
|
meta: {
|
|
35372
35892
|
name: "images",
|
|
35373
35893
|
description: `Find, source, and normalize images. Subcommands route by provider so cost + license are explicit.
|
|
@@ -35440,17 +35960,17 @@ Full guide: __tooling__/docs/tools/baker/images.md`
|
|
|
35440
35960
|
layerize: layerizeCommand,
|
|
35441
35961
|
layers: layersCommand,
|
|
35442
35962
|
upscale: upscaleCommand,
|
|
35443
|
-
tags:
|
|
35963
|
+
tags: tagsCommand3
|
|
35444
35964
|
}
|
|
35445
35965
|
});
|
|
35446
35966
|
|
|
35447
35967
|
// src/commands/landing/index.ts
|
|
35448
|
-
import { defineCommand as
|
|
35968
|
+
import { defineCommand as defineCommand161 } from "citty";
|
|
35449
35969
|
|
|
35450
35970
|
// src/commands/landing/critique.ts
|
|
35451
35971
|
import { readdir as readdir9, stat as stat6 } from "fs/promises";
|
|
35452
35972
|
import path29 from "path";
|
|
35453
|
-
import { defineCommand as
|
|
35973
|
+
import { defineCommand as defineCommand151 } from "citty";
|
|
35454
35974
|
|
|
35455
35975
|
// src/engine/landing/lib/constants.ts
|
|
35456
35976
|
var OVERUSED_FONTS = /* @__PURE__ */ new Set([
|
|
@@ -36633,7 +37153,7 @@ function fail5(code, message, fix) {
|
|
|
36633
37153
|
);
|
|
36634
37154
|
process.exit(2);
|
|
36635
37155
|
}
|
|
36636
|
-
var critiqueCommand2 =
|
|
37156
|
+
var critiqueCommand2 = defineCommand151({
|
|
36637
37157
|
meta: {
|
|
36638
37158
|
name: "critique",
|
|
36639
37159
|
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."
|
|
@@ -36742,10 +37262,10 @@ async function isDir(p) {
|
|
|
36742
37262
|
}
|
|
36743
37263
|
|
|
36744
37264
|
// src/commands/landing/inspiration/index.ts
|
|
36745
|
-
import { defineCommand as
|
|
37265
|
+
import { defineCommand as defineCommand160 } from "citty";
|
|
36746
37266
|
|
|
36747
37267
|
// src/commands/landing/inspiration/add.ts
|
|
36748
|
-
import { defineCommand as
|
|
37268
|
+
import { defineCommand as defineCommand152 } from "citty";
|
|
36749
37269
|
|
|
36750
37270
|
// src/commands/landing/inspiration/shared.ts
|
|
36751
37271
|
var INSPIRATION_HINTS = {
|
|
@@ -36827,7 +37347,7 @@ registerSchema({
|
|
|
36827
37347
|
note: { type: "string", description: "Why this page is worth keeping", required: false }
|
|
36828
37348
|
}
|
|
36829
37349
|
});
|
|
36830
|
-
var addCommand =
|
|
37350
|
+
var addCommand = defineCommand152({
|
|
36831
37351
|
meta: {
|
|
36832
37352
|
name: "add",
|
|
36833
37353
|
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'"
|
|
@@ -36869,7 +37389,7 @@ var addCommand = defineCommand151({
|
|
|
36869
37389
|
// src/commands/landing/inspiration/code.ts
|
|
36870
37390
|
import { mkdir as mkdir10, writeFile as writeFile14 } from "fs/promises";
|
|
36871
37391
|
import path30 from "path";
|
|
36872
|
-
import { defineCommand as
|
|
37392
|
+
import { defineCommand as defineCommand153 } from "citty";
|
|
36873
37393
|
registerSchema({
|
|
36874
37394
|
command: "landing.inspiration.code",
|
|
36875
37395
|
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.",
|
|
@@ -36878,7 +37398,7 @@ registerSchema({
|
|
|
36878
37398
|
full: { type: "boolean", description: "Print the markup inline as well as writing it", required: false }
|
|
36879
37399
|
}
|
|
36880
37400
|
});
|
|
36881
|
-
var codeCommand =
|
|
37401
|
+
var codeCommand = defineCommand153({
|
|
36882
37402
|
meta: {
|
|
36883
37403
|
name: "code",
|
|
36884
37404
|
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."
|
|
@@ -36935,7 +37455,7 @@ var codeCommand = defineCommand152({
|
|
|
36935
37455
|
});
|
|
36936
37456
|
|
|
36937
37457
|
// src/commands/landing/inspiration/favorites.ts
|
|
36938
|
-
import { defineCommand as
|
|
37458
|
+
import { defineCommand as defineCommand154 } from "citty";
|
|
36939
37459
|
registerSchema({
|
|
36940
37460
|
command: "landing.inspiration.favorites",
|
|
36941
37461
|
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.",
|
|
@@ -36949,7 +37469,7 @@ registerSchema({
|
|
|
36949
37469
|
}
|
|
36950
37470
|
}
|
|
36951
37471
|
});
|
|
36952
|
-
var favoritesCommand =
|
|
37472
|
+
var favoritesCommand = defineCommand154({
|
|
36953
37473
|
meta: {
|
|
36954
37474
|
name: "favorites",
|
|
36955
37475
|
description: "List this company's saved reference sections. Example: baker landing inspiration favorites --type hero,pricing"
|
|
@@ -37029,7 +37549,7 @@ registerSchema({
|
|
|
37029
37549
|
note: { type: "string", description: "Why this is worth keeping", required: false }
|
|
37030
37550
|
}
|
|
37031
37551
|
});
|
|
37032
|
-
var favoriteCommand =
|
|
37552
|
+
var favoriteCommand = defineCommand154({
|
|
37033
37553
|
meta: {
|
|
37034
37554
|
name: "favorite",
|
|
37035
37555
|
description: "Save a reference section to this company. Example: baker landing inspiration favorite k57abc\u2026"
|
|
@@ -37067,7 +37587,7 @@ registerSchema({
|
|
|
37067
37587
|
page: { type: "boolean", description: "Treat the id as a page rather than a section", required: false }
|
|
37068
37588
|
}
|
|
37069
37589
|
});
|
|
37070
|
-
var unfavoriteCommand =
|
|
37590
|
+
var unfavoriteCommand = defineCommand154({
|
|
37071
37591
|
meta: {
|
|
37072
37592
|
name: "unfavorite",
|
|
37073
37593
|
description: "Remove a reference section from this company's saved set. Example: baker landing inspiration unfavorite k57abc\u2026"
|
|
@@ -37089,7 +37609,7 @@ var unfavoriteCommand = defineCommand153({
|
|
|
37089
37609
|
});
|
|
37090
37610
|
|
|
37091
37611
|
// src/commands/landing/inspiration/page.ts
|
|
37092
|
-
import { defineCommand as
|
|
37612
|
+
import { defineCommand as defineCommand155 } from "citty";
|
|
37093
37613
|
registerSchema({
|
|
37094
37614
|
command: "landing.inspiration.page",
|
|
37095
37615
|
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.",
|
|
@@ -37106,7 +37626,7 @@ registerSchema({
|
|
|
37106
37626
|
}
|
|
37107
37627
|
}
|
|
37108
37628
|
});
|
|
37109
|
-
var
|
|
37629
|
+
var pageCommand2 = defineCommand155({
|
|
37110
37630
|
meta: {
|
|
37111
37631
|
name: "page",
|
|
37112
37632
|
description: "Show how a reference page sequences its sections. Example: baker landing inspiration page j91xyz\u2026 \u2014 the blueprint, not the pixels."
|
|
@@ -37171,7 +37691,7 @@ var pageCommand = defineCommand154({
|
|
|
37171
37691
|
// src/commands/landing/inspiration/scrape.ts
|
|
37172
37692
|
import { readFile as readFile23 } from "fs/promises";
|
|
37173
37693
|
import path33 from "path";
|
|
37174
|
-
import { defineCommand as
|
|
37694
|
+
import { defineCommand as defineCommand156 } from "citty";
|
|
37175
37695
|
|
|
37176
37696
|
// src/engine/landing/lib/capturedReferences.ts
|
|
37177
37697
|
var MAX_STRINGS_PER_SECTION = 40;
|
|
@@ -39312,7 +39832,7 @@ registerSchema({
|
|
|
39312
39832
|
report: { type: "boolean", description: "Write report.html. `--no-report` to skip", required: false }
|
|
39313
39833
|
}
|
|
39314
39834
|
});
|
|
39315
|
-
var scrapeCommand =
|
|
39835
|
+
var scrapeCommand = defineCommand156({
|
|
39316
39836
|
meta: {
|
|
39317
39837
|
name: "scrape",
|
|
39318
39838
|
description: "Capture a landing page to a directory, now. Example: baker landing inspiration scrape https://linear.app --out .baker/inspiration/linear.app"
|
|
@@ -39414,7 +39934,7 @@ var scrapeCommand = defineCommand155({
|
|
|
39414
39934
|
|
|
39415
39935
|
// src/commands/landing/inspiration/search.ts
|
|
39416
39936
|
import path35 from "path";
|
|
39417
|
-
import { defineCommand as
|
|
39937
|
+
import { defineCommand as defineCommand157 } from "citty";
|
|
39418
39938
|
|
|
39419
39939
|
// src/commands/landing/inspiration/shot.ts
|
|
39420
39940
|
import { mkdir as mkdir12, writeFile as writeFile17 } from "fs/promises";
|
|
@@ -39551,7 +40071,7 @@ async function downloadShots(results) {
|
|
|
39551
40071
|
);
|
|
39552
40072
|
return saved;
|
|
39553
40073
|
}
|
|
39554
|
-
var searchCommand2 =
|
|
40074
|
+
var searchCommand2 = defineCommand157({
|
|
39555
40075
|
meta: {
|
|
39556
40076
|
name: "search",
|
|
39557
40077
|
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"
|
|
@@ -39649,7 +40169,7 @@ var searchCommand2 = defineCommand156({
|
|
|
39649
40169
|
});
|
|
39650
40170
|
|
|
39651
40171
|
// src/commands/landing/inspiration/sequences.ts
|
|
39652
|
-
import { defineCommand as
|
|
40172
|
+
import { defineCommand as defineCommand158 } from "citty";
|
|
39653
40173
|
var COMPACT_TRANSITIONS = 12;
|
|
39654
40174
|
var COMPACT_ENDS = 5;
|
|
39655
40175
|
var MAX_PAGES = 50;
|
|
@@ -39723,7 +40243,7 @@ function sequencesHints(data, { scope, full }) {
|
|
|
39723
40243
|
if (scope === "favorites") hints.push(...favoritesScopeHints(data.favoritesHealth, data.pagesReturned));
|
|
39724
40244
|
return hints;
|
|
39725
40245
|
}
|
|
39726
|
-
var sequencesCommand =
|
|
40246
|
+
var sequencesCommand = defineCommand158({
|
|
39727
40247
|
meta: {
|
|
39728
40248
|
name: "sequences",
|
|
39729
40249
|
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."
|
|
@@ -39773,7 +40293,7 @@ var sequencesCommand = defineCommand157({
|
|
|
39773
40293
|
|
|
39774
40294
|
// src/commands/landing/inspiration/view.ts
|
|
39775
40295
|
import path36 from "path";
|
|
39776
|
-
import { defineCommand as
|
|
40296
|
+
import { defineCommand as defineCommand159 } from "citty";
|
|
39777
40297
|
registerSchema({
|
|
39778
40298
|
command: "landing.inspiration.view",
|
|
39779
40299
|
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.",
|
|
@@ -39786,7 +40306,7 @@ registerSchema({
|
|
|
39786
40306
|
}
|
|
39787
40307
|
}
|
|
39788
40308
|
});
|
|
39789
|
-
var viewCommand2 =
|
|
40309
|
+
var viewCommand2 = defineCommand159({
|
|
39790
40310
|
meta: {
|
|
39791
40311
|
name: "view",
|
|
39792
40312
|
description: "Full detail for one reference section. Example: baker landing inspiration view k57abc\u2026 \u2014 read the screenshots it saves before you build."
|
|
@@ -39870,7 +40390,7 @@ var viewCommand2 = defineCommand158({
|
|
|
39870
40390
|
});
|
|
39871
40391
|
|
|
39872
40392
|
// src/commands/landing/inspiration/index.ts
|
|
39873
|
-
var inspirationCommand =
|
|
40393
|
+
var inspirationCommand = defineCommand160({
|
|
39874
40394
|
meta: {
|
|
39875
40395
|
name: "inspiration",
|
|
39876
40396
|
description: `Reference library of real landing-page sections \u2014 look at how good pages actually solve a problem before you design one.
|
|
@@ -39904,7 +40424,7 @@ Full guide: __tooling__/docs/tools/baker/landing.md`
|
|
|
39904
40424
|
search: searchCommand2,
|
|
39905
40425
|
view: viewCommand2,
|
|
39906
40426
|
code: codeCommand,
|
|
39907
|
-
page:
|
|
40427
|
+
page: pageCommand2,
|
|
39908
40428
|
sequences: sequencesCommand,
|
|
39909
40429
|
add: addCommand,
|
|
39910
40430
|
favorites: favoritesCommand,
|
|
@@ -39915,7 +40435,7 @@ Full guide: __tooling__/docs/tools/baker/landing.md`
|
|
|
39915
40435
|
});
|
|
39916
40436
|
|
|
39917
40437
|
// src/commands/landing/index.ts
|
|
39918
|
-
var landingCommand =
|
|
40438
|
+
var landingCommand = defineCommand161({
|
|
39919
40439
|
meta: {
|
|
39920
40440
|
name: "landing",
|
|
39921
40441
|
description: `Design-quality tools for landing pages (src/pages/<slug>/).
|
|
@@ -39933,7 +40453,7 @@ Subcommands:
|
|
|
39933
40453
|
});
|
|
39934
40454
|
|
|
39935
40455
|
// src/commands/mcp/index.ts
|
|
39936
|
-
import { defineCommand as
|
|
40456
|
+
import { defineCommand as defineCommand162 } from "citty";
|
|
39937
40457
|
|
|
39938
40458
|
// src/commands/mcp/platforms.ts
|
|
39939
40459
|
function readsKey(label) {
|
|
@@ -40002,7 +40522,7 @@ registerSchema({
|
|
|
40002
40522
|
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.",
|
|
40003
40523
|
args: {}
|
|
40004
40524
|
});
|
|
40005
|
-
var connectedCommand =
|
|
40525
|
+
var connectedCommand = defineCommand162({
|
|
40006
40526
|
meta: {
|
|
40007
40527
|
name: "connected",
|
|
40008
40528
|
description: `Everything this chat can reach \u2014 managed integrations, custom MCP servers, and connected platforms.
|
|
@@ -40061,7 +40581,7 @@ registerSchema({
|
|
|
40061
40581
|
description: "List the custom MCP servers this company's chats see (org + company + your own user scope).",
|
|
40062
40582
|
args: {}
|
|
40063
40583
|
});
|
|
40064
|
-
var listCommand14 =
|
|
40584
|
+
var listCommand14 = defineCommand162({
|
|
40065
40585
|
meta: { name: "list", description: "List custom MCP servers visible to this company's chats." },
|
|
40066
40586
|
run: async () => {
|
|
40067
40587
|
try {
|
|
@@ -40098,7 +40618,7 @@ registerSchema({
|
|
|
40098
40618
|
header: { type: "string", description: 'Auth header "Key: Value" (repeatable)', required: false }
|
|
40099
40619
|
}
|
|
40100
40620
|
});
|
|
40101
|
-
var addCommand2 =
|
|
40621
|
+
var addCommand2 = defineCommand162({
|
|
40102
40622
|
meta: {
|
|
40103
40623
|
name: "add",
|
|
40104
40624
|
description: `Register a custom MCP server. Tools appear as mcp__<name>__* on the NEXT message.
|
|
@@ -40150,7 +40670,7 @@ registerSchema({
|
|
|
40150
40670
|
description: "Remove a company custom MCP server by name.",
|
|
40151
40671
|
args: { name: { type: "string", description: "Server name to remove", required: true } }
|
|
40152
40672
|
});
|
|
40153
|
-
var removeCommand4 =
|
|
40673
|
+
var removeCommand4 = defineCommand162({
|
|
40154
40674
|
meta: {
|
|
40155
40675
|
name: "remove",
|
|
40156
40676
|
description: `Remove a company custom MCP server by name.
|
|
@@ -40172,7 +40692,7 @@ Example:
|
|
|
40172
40692
|
}
|
|
40173
40693
|
}
|
|
40174
40694
|
});
|
|
40175
|
-
var mcpCommand =
|
|
40695
|
+
var mcpCommand = defineCommand162({
|
|
40176
40696
|
meta: {
|
|
40177
40697
|
name: "mcp",
|
|
40178
40698
|
description: `Third-party tools for this company \u2014 see what's connected, register custom HTTPS MCP endpoints.
|
|
@@ -40198,10 +40718,10 @@ Full guide: __tooling__/docs/tools/baker/mcp.md`
|
|
|
40198
40718
|
});
|
|
40199
40719
|
|
|
40200
40720
|
// src/commands/research/index.ts
|
|
40201
|
-
import { defineCommand as
|
|
40721
|
+
import { defineCommand as defineCommand174 } from "citty";
|
|
40202
40722
|
|
|
40203
40723
|
// src/commands/research/advertisers.ts
|
|
40204
|
-
import { defineCommand as
|
|
40724
|
+
import { defineCommand as defineCommand163 } from "citty";
|
|
40205
40725
|
|
|
40206
40726
|
// src/commands/research/hints.ts
|
|
40207
40727
|
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.';
|
|
@@ -40384,7 +40904,7 @@ var FIELDS3 = {
|
|
|
40384
40904
|
etv: "Estimated traffic value (USD)",
|
|
40385
40905
|
visibility: "SERP visibility score (0-1)"
|
|
40386
40906
|
};
|
|
40387
|
-
var advertisersCommand =
|
|
40907
|
+
var advertisersCommand = defineCommand163({
|
|
40388
40908
|
meta: {
|
|
40389
40909
|
name: "advertisers",
|
|
40390
40910
|
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).
|
|
@@ -40440,7 +40960,7 @@ Examples:
|
|
|
40440
40960
|
});
|
|
40441
40961
|
|
|
40442
40962
|
// src/commands/research/autocomplete.ts
|
|
40443
|
-
import { defineCommand as
|
|
40963
|
+
import { defineCommand as defineCommand164 } from "citty";
|
|
40444
40964
|
registerSchema({
|
|
40445
40965
|
command: "research.autocomplete",
|
|
40446
40966
|
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).",
|
|
@@ -40463,7 +40983,7 @@ registerSchema({
|
|
|
40463
40983
|
var FIELDS4 = {
|
|
40464
40984
|
suggestion: "Autocomplete suggestion from Google"
|
|
40465
40985
|
};
|
|
40466
|
-
var autocompleteCommand =
|
|
40986
|
+
var autocompleteCommand = defineCommand164({
|
|
40467
40987
|
meta: {
|
|
40468
40988
|
name: "autocomplete",
|
|
40469
40989
|
description: `Get Google Autocomplete suggestions for keyword expansion.
|
|
@@ -40518,7 +41038,7 @@ Examples:
|
|
|
40518
41038
|
});
|
|
40519
41039
|
|
|
40520
41040
|
// src/commands/research/countries.ts
|
|
40521
|
-
import { defineCommand as
|
|
41041
|
+
import { defineCommand as defineCommand165 } from "citty";
|
|
40522
41042
|
registerSchema({
|
|
40523
41043
|
command: "research.countries",
|
|
40524
41044
|
description: "List all supported country codes for --location flag in research commands.",
|
|
@@ -40575,7 +41095,7 @@ var FIELDS5 = {
|
|
|
40575
41095
|
code: "Country code to pass as --location",
|
|
40576
41096
|
name: "Country name"
|
|
40577
41097
|
};
|
|
40578
|
-
var countriesCommand =
|
|
41098
|
+
var countriesCommand = defineCommand165({
|
|
40579
41099
|
meta: {
|
|
40580
41100
|
name: "countries",
|
|
40581
41101
|
description: "List all supported country codes for --location flag."
|
|
@@ -40586,7 +41106,7 @@ var countriesCommand = defineCommand164({
|
|
|
40586
41106
|
});
|
|
40587
41107
|
|
|
40588
41108
|
// src/commands/research/fetch.ts
|
|
40589
|
-
import { defineCommand as
|
|
41109
|
+
import { defineCommand as defineCommand166 } from "citty";
|
|
40590
41110
|
var CONTENT_PREVIEW_CHARS = 2e4;
|
|
40591
41111
|
var TIMEOUT_MS = 18e4;
|
|
40592
41112
|
registerSchema({
|
|
@@ -40659,7 +41179,7 @@ function fetchFix(code) {
|
|
|
40659
41179
|
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."
|
|
40660
41180
|
};
|
|
40661
41181
|
}
|
|
40662
|
-
var fetchCommand =
|
|
41182
|
+
var fetchCommand = defineCommand166({
|
|
40663
41183
|
meta: {
|
|
40664
41184
|
name: "fetch",
|
|
40665
41185
|
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.
|
|
@@ -40736,7 +41256,7 @@ Examples:
|
|
|
40736
41256
|
});
|
|
40737
41257
|
|
|
40738
41258
|
// src/commands/research/intent.ts
|
|
40739
|
-
import { defineCommand as
|
|
41259
|
+
import { defineCommand as defineCommand167 } from "citty";
|
|
40740
41260
|
registerSchema({
|
|
40741
41261
|
command: "research.intent",
|
|
40742
41262
|
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.",
|
|
@@ -40759,7 +41279,7 @@ var FIELDS7 = {
|
|
|
40759
41279
|
intent: "Primary Google Search intent: informational, navigational, commercial, transactional",
|
|
40760
41280
|
probability: "Confidence score 0.0-1.0"
|
|
40761
41281
|
};
|
|
40762
|
-
var intentCommand =
|
|
41282
|
+
var intentCommand = defineCommand167({
|
|
40763
41283
|
meta: {
|
|
40764
41284
|
name: "intent",
|
|
40765
41285
|
description: `Classify Google Search intent for keywords. Returns intent type and confidence.
|
|
@@ -40807,7 +41327,7 @@ Examples:
|
|
|
40807
41327
|
});
|
|
40808
41328
|
|
|
40809
41329
|
// src/commands/research/keyword-gap.ts
|
|
40810
|
-
import { defineCommand as
|
|
41330
|
+
import { defineCommand as defineCommand168 } from "citty";
|
|
40811
41331
|
registerSchema({
|
|
40812
41332
|
command: "research.keyword-gap",
|
|
40813
41333
|
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.",
|
|
@@ -40836,7 +41356,7 @@ var FIELDS8 = {
|
|
|
40836
41356
|
cpc: "Cost per click USD",
|
|
40837
41357
|
their_position: "Competitor's ranking position"
|
|
40838
41358
|
};
|
|
40839
|
-
var keywordGapCommand =
|
|
41359
|
+
var keywordGapCommand = defineCommand168({
|
|
40840
41360
|
meta: {
|
|
40841
41361
|
name: "keyword-gap",
|
|
40842
41362
|
description: `Find keywords a competitor has that you don't. Supports pagination via --offset.
|
|
@@ -40911,7 +41431,7 @@ Examples:
|
|
|
40911
41431
|
});
|
|
40912
41432
|
|
|
40913
41433
|
// src/commands/research/keywords-for-site.ts
|
|
40914
|
-
import { defineCommand as
|
|
41434
|
+
import { defineCommand as defineCommand169 } from "citty";
|
|
40915
41435
|
registerSchema({
|
|
40916
41436
|
command: "research.keywords-for-site",
|
|
40917
41437
|
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.",
|
|
@@ -40944,7 +41464,7 @@ var FIELDS9 = {
|
|
|
40944
41464
|
competition: "LOW, MEDIUM, or HIGH",
|
|
40945
41465
|
competition_index: "Competition score 0-100"
|
|
40946
41466
|
};
|
|
40947
|
-
var keywordsForSiteCommand =
|
|
41467
|
+
var keywordsForSiteCommand = defineCommand169({
|
|
40948
41468
|
meta: {
|
|
40949
41469
|
name: "keywords-for-site",
|
|
40950
41470
|
description: `Get keywords a competitor targets in Google. Use --type to filter paid/organic.
|
|
@@ -41006,7 +41526,7 @@ Examples:
|
|
|
41006
41526
|
});
|
|
41007
41527
|
|
|
41008
41528
|
// src/commands/research/languages.ts
|
|
41009
|
-
import { defineCommand as
|
|
41529
|
+
import { defineCommand as defineCommand170 } from "citty";
|
|
41010
41530
|
registerSchema({
|
|
41011
41531
|
command: "research.languages",
|
|
41012
41532
|
description: "List all supported language codes for --language flag in research commands.",
|
|
@@ -41036,7 +41556,7 @@ var FIELDS10 = {
|
|
|
41036
41556
|
code: "Language code to pass as --language",
|
|
41037
41557
|
name: "Language name (also accepted by --language)"
|
|
41038
41558
|
};
|
|
41039
|
-
var languagesCommand2 =
|
|
41559
|
+
var languagesCommand2 = defineCommand170({
|
|
41040
41560
|
meta: {
|
|
41041
41561
|
name: "languages",
|
|
41042
41562
|
description: "List all supported language codes for --language flag."
|
|
@@ -41047,7 +41567,7 @@ var languagesCommand2 = defineCommand169({
|
|
|
41047
41567
|
});
|
|
41048
41568
|
|
|
41049
41569
|
// src/commands/research/lighthouse.ts
|
|
41050
|
-
import { defineCommand as
|
|
41570
|
+
import { defineCommand as defineCommand171 } from "citty";
|
|
41051
41571
|
registerSchema({
|
|
41052
41572
|
command: "research.lighthouse",
|
|
41053
41573
|
description: "Landing page performance audit. Returns metrics that affect Google Ads Quality Score and CPC.",
|
|
@@ -41066,7 +41586,7 @@ var FIELDS11 = {
|
|
|
41066
41586
|
speed_index_ms: "Speed Index in ms (good: < 3400)",
|
|
41067
41587
|
interactive_ms: "Time to Interactive in ms (good: < 3800)"
|
|
41068
41588
|
};
|
|
41069
|
-
var lighthouseCommand =
|
|
41589
|
+
var lighthouseCommand = defineCommand171({
|
|
41070
41590
|
meta: {
|
|
41071
41591
|
name: "lighthouse",
|
|
41072
41592
|
description: `Landing page performance audit. Metrics affecting Google Ads Quality Score.
|
|
@@ -41104,7 +41624,7 @@ Examples:
|
|
|
41104
41624
|
});
|
|
41105
41625
|
|
|
41106
41626
|
// src/commands/research/relevant-pages.ts
|
|
41107
|
-
import { defineCommand as
|
|
41627
|
+
import { defineCommand as defineCommand172 } from "citty";
|
|
41108
41628
|
registerSchema({
|
|
41109
41629
|
command: "research.relevant-pages",
|
|
41110
41630
|
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).",
|
|
@@ -41130,7 +41650,7 @@ var FIELDS12 = {
|
|
|
41130
41650
|
keywords: "Total organic keywords the page ranks for",
|
|
41131
41651
|
top_10: "Keywords in positions 1-10"
|
|
41132
41652
|
};
|
|
41133
|
-
var relevantPagesCommand =
|
|
41653
|
+
var relevantPagesCommand = defineCommand172({
|
|
41134
41654
|
meta: {
|
|
41135
41655
|
name: "relevant-pages",
|
|
41136
41656
|
description: `Get the top pages of a competitor domain with traffic data.
|
|
@@ -41177,7 +41697,7 @@ Examples:
|
|
|
41177
41697
|
});
|
|
41178
41698
|
|
|
41179
41699
|
// src/commands/research/web.ts
|
|
41180
|
-
import { defineCommand as
|
|
41700
|
+
import { defineCommand as defineCommand173 } from "citty";
|
|
41181
41701
|
registerSchema({
|
|
41182
41702
|
command: "research.web",
|
|
41183
41703
|
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).",
|
|
@@ -41228,7 +41748,7 @@ async function runDeepResearch(question) {
|
|
|
41228
41748
|
}
|
|
41229
41749
|
throw new Error("Deep research timed out");
|
|
41230
41750
|
}
|
|
41231
|
-
var webCommand =
|
|
41751
|
+
var webCommand = defineCommand173({
|
|
41232
41752
|
meta: {
|
|
41233
41753
|
name: "web",
|
|
41234
41754
|
description: `Search the web with AI to answer any open-ended marketing question. Uses live internet data via Google Search.
|
|
@@ -41290,7 +41810,7 @@ Examples:
|
|
|
41290
41810
|
});
|
|
41291
41811
|
|
|
41292
41812
|
// src/commands/research/index.ts
|
|
41293
|
-
var researchCommand =
|
|
41813
|
+
var researchCommand = defineCommand174({
|
|
41294
41814
|
meta: {
|
|
41295
41815
|
name: "research",
|
|
41296
41816
|
description: `Competitive intelligence and AI-powered research commands.
|
|
@@ -41334,10 +41854,10 @@ Full guide: __tooling__/docs/tools/baker/research.md`
|
|
|
41334
41854
|
});
|
|
41335
41855
|
|
|
41336
41856
|
// src/commands/scheduled-actions/index.ts
|
|
41337
|
-
import { defineCommand as
|
|
41857
|
+
import { defineCommand as defineCommand182 } from "citty";
|
|
41338
41858
|
|
|
41339
41859
|
// src/commands/scheduled-actions/create.ts
|
|
41340
|
-
import { defineCommand as
|
|
41860
|
+
import { defineCommand as defineCommand175 } from "citty";
|
|
41341
41861
|
|
|
41342
41862
|
// src/commands/scheduled-actions/shared.ts
|
|
41343
41863
|
var TEMP_SCHEDULED_ACTION_PREFIX = "temp_sched_";
|
|
@@ -41457,7 +41977,7 @@ registerSchema({
|
|
|
41457
41977
|
}
|
|
41458
41978
|
}
|
|
41459
41979
|
});
|
|
41460
|
-
var createCommand3 =
|
|
41980
|
+
var createCommand3 = defineCommand175({
|
|
41461
41981
|
meta: {
|
|
41462
41982
|
name: "create",
|
|
41463
41983
|
description: 'Stage a scheduled action. Example: baker scheduled-actions create --name "Weekly report" --description "..." --cron "0 9 * * MON"'
|
|
@@ -41510,7 +42030,7 @@ var createCommand3 = defineCommand174({
|
|
|
41510
42030
|
});
|
|
41511
42031
|
|
|
41512
42032
|
// src/commands/scheduled-actions/delete.ts
|
|
41513
|
-
import { defineCommand as
|
|
42033
|
+
import { defineCommand as defineCommand176 } from "citty";
|
|
41514
42034
|
registerSchema({
|
|
41515
42035
|
command: "scheduled-actions.delete",
|
|
41516
42036
|
description: "Stage deletion of a published scheduled action or cancellation of a temp_sched_* draft creation.",
|
|
@@ -41518,7 +42038,7 @@ registerSchema({
|
|
|
41518
42038
|
id: { type: "string", description: "Published scheduled action ID or temp_sched_* draft ID", required: true }
|
|
41519
42039
|
}
|
|
41520
42040
|
});
|
|
41521
|
-
var deleteCommand3 =
|
|
42041
|
+
var deleteCommand3 = defineCommand176({
|
|
41522
42042
|
meta: {
|
|
41523
42043
|
name: "delete",
|
|
41524
42044
|
description: "Stage scheduled action deletion. Example: baker scheduled-actions delete <id-or-temp_sched_id>"
|
|
@@ -41547,7 +42067,7 @@ var deleteCommand3 = defineCommand175({
|
|
|
41547
42067
|
});
|
|
41548
42068
|
|
|
41549
42069
|
// src/commands/scheduled-actions/get.ts
|
|
41550
|
-
import { defineCommand as
|
|
42070
|
+
import { defineCommand as defineCommand177 } from "citty";
|
|
41551
42071
|
registerSchema({
|
|
41552
42072
|
command: "scheduled-actions.get",
|
|
41553
42073
|
description: "Get a published scheduled action or a temp_sched_* draft-created scheduled action.",
|
|
@@ -41556,7 +42076,7 @@ registerSchema({
|
|
|
41556
42076
|
chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
|
|
41557
42077
|
}
|
|
41558
42078
|
});
|
|
41559
|
-
var getCommand4 =
|
|
42079
|
+
var getCommand4 = defineCommand177({
|
|
41560
42080
|
meta: {
|
|
41561
42081
|
name: "get",
|
|
41562
42082
|
description: "Get a scheduled action. Example: baker scheduled-actions get <id-or-temp_sched_id>"
|
|
@@ -41595,7 +42115,7 @@ var getCommand4 = defineCommand176({
|
|
|
41595
42115
|
});
|
|
41596
42116
|
|
|
41597
42117
|
// src/commands/scheduled-actions/list.ts
|
|
41598
|
-
import { defineCommand as
|
|
42118
|
+
import { defineCommand as defineCommand178 } from "citty";
|
|
41599
42119
|
registerSchema({
|
|
41600
42120
|
command: "scheduled-actions.list",
|
|
41601
42121
|
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.",
|
|
@@ -41603,7 +42123,7 @@ registerSchema({
|
|
|
41603
42123
|
chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
|
|
41604
42124
|
}
|
|
41605
42125
|
});
|
|
41606
|
-
var listCommand15 =
|
|
42126
|
+
var listCommand15 = defineCommand178({
|
|
41607
42127
|
meta: {
|
|
41608
42128
|
name: "list",
|
|
41609
42129
|
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."
|
|
@@ -41628,7 +42148,7 @@ var listCommand15 = defineCommand177({
|
|
|
41628
42148
|
// src/commands/scheduled-actions/templates.ts
|
|
41629
42149
|
import { readFile as readFile24 } from "fs/promises";
|
|
41630
42150
|
import path37 from "path";
|
|
41631
|
-
import { defineCommand as
|
|
42151
|
+
import { defineCommand as defineCommand179 } from "citty";
|
|
41632
42152
|
registerSchema({
|
|
41633
42153
|
command: "scheduled-actions.templates",
|
|
41634
42154
|
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.",
|
|
@@ -41683,7 +42203,7 @@ registerSchema({
|
|
|
41683
42203
|
}
|
|
41684
42204
|
}
|
|
41685
42205
|
});
|
|
41686
|
-
var templatesCommand =
|
|
42206
|
+
var templatesCommand = defineCommand179({
|
|
41687
42207
|
meta: {
|
|
41688
42208
|
name: "templates",
|
|
41689
42209
|
description: `The recipes this company can run \u2014 Baker's own plus theirs, with what each one produces.
|
|
@@ -41775,7 +42295,7 @@ Full guide: __tooling__/docs/tools/baker/scheduled-actions.md`
|
|
|
41775
42295
|
});
|
|
41776
42296
|
|
|
41777
42297
|
// src/commands/scheduled-actions/trigger.ts
|
|
41778
|
-
import { defineCommand as
|
|
42298
|
+
import { defineCommand as defineCommand180 } from "citty";
|
|
41779
42299
|
registerSchema({
|
|
41780
42300
|
command: "scheduled-actions.trigger",
|
|
41781
42301
|
description: "Immediately trigger a published scheduled action. Does not require BAKER_CHAT_ID and rejects temp_sched_* IDs.",
|
|
@@ -41783,7 +42303,7 @@ registerSchema({
|
|
|
41783
42303
|
id: { type: "string", description: "Published scheduled action ID", required: true }
|
|
41784
42304
|
}
|
|
41785
42305
|
});
|
|
41786
|
-
var triggerCommand =
|
|
42306
|
+
var triggerCommand = defineCommand180({
|
|
41787
42307
|
meta: {
|
|
41788
42308
|
name: "trigger",
|
|
41789
42309
|
description: "Immediately trigger a published scheduled action. Example: baker scheduled-actions trigger <id>"
|
|
@@ -41820,7 +42340,7 @@ var triggerCommand = defineCommand179({
|
|
|
41820
42340
|
});
|
|
41821
42341
|
|
|
41822
42342
|
// src/commands/scheduled-actions/update.ts
|
|
41823
|
-
import { defineCommand as
|
|
42343
|
+
import { defineCommand as defineCommand181 } from "citty";
|
|
41824
42344
|
registerSchema({
|
|
41825
42345
|
command: "scheduled-actions.update",
|
|
41826
42346
|
description: "Stage an update to a published scheduled action or temp_sched_* draft-created scheduled action.",
|
|
@@ -41845,7 +42365,7 @@ registerSchema({
|
|
|
41845
42365
|
prompt: { type: "string", description: "Replacement additional spawned-agent instructions", required: false }
|
|
41846
42366
|
}
|
|
41847
42367
|
});
|
|
41848
|
-
var updateCommand3 =
|
|
42368
|
+
var updateCommand3 = defineCommand181({
|
|
41849
42369
|
meta: {
|
|
41850
42370
|
name: "update",
|
|
41851
42371
|
description: "Stage a scheduled action update. Example: baker scheduled-actions update <id> --enabled false"
|
|
@@ -41916,7 +42436,7 @@ var updateCommand3 = defineCommand180({
|
|
|
41916
42436
|
});
|
|
41917
42437
|
|
|
41918
42438
|
// src/commands/scheduled-actions/index.ts
|
|
41919
|
-
var scheduledActionsCommand =
|
|
42439
|
+
var scheduledActionsCommand = defineCommand182({
|
|
41920
42440
|
meta: {
|
|
41921
42441
|
name: "scheduled-actions",
|
|
41922
42442
|
description: `Manage Scheduled Actions. Subcommands: list, get, create, update, delete, trigger, templates.
|
|
@@ -41944,14 +42464,14 @@ Full guide: __tooling__/docs/tools/baker/scheduled-actions.md`
|
|
|
41944
42464
|
});
|
|
41945
42465
|
|
|
41946
42466
|
// src/commands/schema.ts
|
|
41947
|
-
import { defineCommand as
|
|
42467
|
+
import { defineCommand as defineCommand183 } from "citty";
|
|
41948
42468
|
function narrowToFamily(commandName, available) {
|
|
41949
42469
|
const segments = commandName.split(".");
|
|
41950
42470
|
const prefix = segments[0] === "ads" && segments[1] ? `ads.${segments[1]}.` : `${segments[0]}.`;
|
|
41951
42471
|
const siblings = available.filter((name) => name.startsWith(prefix));
|
|
41952
42472
|
return siblings.length > 0 ? siblings : available;
|
|
41953
42473
|
}
|
|
41954
|
-
var schemaCommand =
|
|
42474
|
+
var schemaCommand = defineCommand183({
|
|
41955
42475
|
meta: {
|
|
41956
42476
|
name: "schema",
|
|
41957
42477
|
description: "Inspect command argument schemas (for AI agent introspection). Lists all commands if no argument given. Example: baker schema images.search"
|
|
@@ -41995,10 +42515,10 @@ var schemaCommand = defineCommand182({
|
|
|
41995
42515
|
});
|
|
41996
42516
|
|
|
41997
42517
|
// src/commands/studio/index.ts
|
|
41998
|
-
import { defineCommand as
|
|
42518
|
+
import { defineCommand as defineCommand192 } from "citty";
|
|
41999
42519
|
|
|
42000
42520
|
// src/commands/studio/animate.ts
|
|
42001
|
-
import { defineCommand as
|
|
42521
|
+
import { defineCommand as defineCommand184 } from "citty";
|
|
42002
42522
|
|
|
42003
42523
|
// src/commands/studio/batch.ts
|
|
42004
42524
|
function projectBatch(generation, full) {
|
|
@@ -42449,7 +42969,7 @@ function costHintsFor(body) {
|
|
|
42449
42969
|
}
|
|
42450
42970
|
return hints;
|
|
42451
42971
|
}
|
|
42452
|
-
var animateCommand =
|
|
42972
|
+
var animateCommand = defineCommand184({
|
|
42453
42973
|
meta: {
|
|
42454
42974
|
name: "animate",
|
|
42455
42975
|
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"
|
|
@@ -42568,7 +43088,7 @@ var animateCommand = defineCommand183({
|
|
|
42568
43088
|
});
|
|
42569
43089
|
|
|
42570
43090
|
// src/commands/studio/generate.ts
|
|
42571
|
-
import { defineCommand as
|
|
43091
|
+
import { defineCommand as defineCommand185 } from "citty";
|
|
42572
43092
|
var MODEL_LIST2 = IMAGE_MODEL_IDS;
|
|
42573
43093
|
var DEFAULT_MAX_WAIT_MS2 = 24e4;
|
|
42574
43094
|
registerSchema({
|
|
@@ -42704,7 +43224,7 @@ function buildGenerateBody(args, prompt) {
|
|
|
42704
43224
|
}
|
|
42705
43225
|
return body;
|
|
42706
43226
|
}
|
|
42707
|
-
var generateCommand =
|
|
43227
|
+
var generateCommand = defineCommand185({
|
|
42708
43228
|
meta: {
|
|
42709
43229
|
name: "generate",
|
|
42710
43230
|
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]]'"
|
|
@@ -42782,7 +43302,7 @@ var generateCommand = defineCommand184({
|
|
|
42782
43302
|
});
|
|
42783
43303
|
|
|
42784
43304
|
// src/commands/studio/get.ts
|
|
42785
|
-
import { defineCommand as
|
|
43305
|
+
import { defineCommand as defineCommand186 } from "citty";
|
|
42786
43306
|
registerSchema({
|
|
42787
43307
|
command: "studio.get",
|
|
42788
43308
|
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.",
|
|
@@ -42791,7 +43311,7 @@ registerSchema({
|
|
|
42791
43311
|
full: { type: "boolean", description: "Include settings, references and attribution", required: false }
|
|
42792
43312
|
}
|
|
42793
43313
|
});
|
|
42794
|
-
var getCommand5 =
|
|
43314
|
+
var getCommand5 = defineCommand186({
|
|
42795
43315
|
meta: {
|
|
42796
43316
|
name: "get",
|
|
42797
43317
|
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"
|
|
@@ -42820,7 +43340,7 @@ var getCommand5 = defineCommand185({
|
|
|
42820
43340
|
});
|
|
42821
43341
|
|
|
42822
43342
|
// src/commands/studio/improve.ts
|
|
42823
|
-
import { defineCommand as
|
|
43343
|
+
import { defineCommand as defineCommand187 } from "citty";
|
|
42824
43344
|
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.";
|
|
42825
43345
|
registerSchema({
|
|
42826
43346
|
command: "studio.improve",
|
|
@@ -42845,7 +43365,7 @@ registerSchema({
|
|
|
42845
43365
|
}
|
|
42846
43366
|
}
|
|
42847
43367
|
});
|
|
42848
|
-
var improveCommand =
|
|
43368
|
+
var improveCommand = defineCommand187({
|
|
42849
43369
|
meta: {
|
|
42850
43370
|
name: "improve",
|
|
42851
43371
|
description: `${DESCRIPTION}
|
|
@@ -42889,7 +43409,7 @@ Examples:
|
|
|
42889
43409
|
});
|
|
42890
43410
|
|
|
42891
43411
|
// src/commands/studio/keep.ts
|
|
42892
|
-
import { defineCommand as
|
|
43412
|
+
import { defineCommand as defineCommand188 } from "citty";
|
|
42893
43413
|
registerSchema({
|
|
42894
43414
|
command: "studio.keep",
|
|
42895
43415
|
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.",
|
|
@@ -42899,7 +43419,7 @@ registerSchema({
|
|
|
42899
43419
|
undo: { type: "boolean", description: "Un-star an image, or take a kept clip back out", required: false }
|
|
42900
43420
|
}
|
|
42901
43421
|
});
|
|
42902
|
-
var keepCommand =
|
|
43422
|
+
var keepCommand = defineCommand188({
|
|
42903
43423
|
meta: {
|
|
42904
43424
|
name: "keep",
|
|
42905
43425
|
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"
|
|
@@ -42950,7 +43470,7 @@ var keepCommand = defineCommand187({
|
|
|
42950
43470
|
});
|
|
42951
43471
|
|
|
42952
43472
|
// src/commands/studio/list.ts
|
|
42953
|
-
import { defineCommand as
|
|
43473
|
+
import { defineCommand as defineCommand189 } from "citty";
|
|
42954
43474
|
registerSchema({
|
|
42955
43475
|
command: "studio.list",
|
|
42956
43476
|
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.",
|
|
@@ -42961,7 +43481,7 @@ registerSchema({
|
|
|
42961
43481
|
full: { type: "boolean", description: "Include settings, references and attribution", required: false }
|
|
42962
43482
|
}
|
|
42963
43483
|
});
|
|
42964
|
-
var listCommand16 =
|
|
43484
|
+
var listCommand16 = defineCommand189({
|
|
42965
43485
|
meta: {
|
|
42966
43486
|
name: "list",
|
|
42967
43487
|
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"
|
|
@@ -42995,7 +43515,7 @@ var listCommand16 = defineCommand188({
|
|
|
42995
43515
|
});
|
|
42996
43516
|
|
|
42997
43517
|
// src/commands/studio/models.ts
|
|
42998
|
-
import { defineCommand as
|
|
43518
|
+
import { defineCommand as defineCommand190 } from "citty";
|
|
42999
43519
|
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.";
|
|
43000
43520
|
registerSchema({
|
|
43001
43521
|
command: "studio.models",
|
|
@@ -43082,7 +43602,7 @@ function buildModelCards(kind, model) {
|
|
|
43082
43602
|
const selected = model ? ids.filter((id) => id === model) : ids;
|
|
43083
43603
|
return selected.map((id) => build(id));
|
|
43084
43604
|
}
|
|
43085
|
-
var modelsCommand =
|
|
43605
|
+
var modelsCommand = defineCommand190({
|
|
43086
43606
|
meta: {
|
|
43087
43607
|
name: "models",
|
|
43088
43608
|
description: `${DESCRIPTION2}
|
|
@@ -43129,13 +43649,13 @@ Examples:
|
|
|
43129
43649
|
});
|
|
43130
43650
|
|
|
43131
43651
|
// src/commands/studio/skills.ts
|
|
43132
|
-
import { defineCommand as
|
|
43652
|
+
import { defineCommand as defineCommand191 } from "citty";
|
|
43133
43653
|
registerSchema({
|
|
43134
43654
|
command: "studio.skills",
|
|
43135
43655
|
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.",
|
|
43136
43656
|
args: {}
|
|
43137
43657
|
});
|
|
43138
|
-
var skillsCommand =
|
|
43658
|
+
var skillsCommand = defineCommand191({
|
|
43139
43659
|
meta: {
|
|
43140
43660
|
name: "skills",
|
|
43141
43661
|
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"
|
|
@@ -43159,7 +43679,7 @@ var skillsCommand = defineCommand190({
|
|
|
43159
43679
|
});
|
|
43160
43680
|
|
|
43161
43681
|
// src/commands/studio/index.ts
|
|
43162
|
-
var studioCommand =
|
|
43682
|
+
var studioCommand = defineCommand192({
|
|
43163
43683
|
meta: {
|
|
43164
43684
|
name: "studio",
|
|
43165
43685
|
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.
|
|
@@ -43202,10 +43722,10 @@ Full guide: __tooling__/docs/tools/baker/studio.md`
|
|
|
43202
43722
|
});
|
|
43203
43723
|
|
|
43204
43724
|
// src/commands/tag-manager/index.ts
|
|
43205
|
-
import { defineCommand as
|
|
43725
|
+
import { defineCommand as defineCommand196 } from "citty";
|
|
43206
43726
|
|
|
43207
43727
|
// src/commands/tag-manager/draft.ts
|
|
43208
|
-
import { defineCommand as
|
|
43728
|
+
import { defineCommand as defineCommand193 } from "citty";
|
|
43209
43729
|
|
|
43210
43730
|
// src/commands/tag-manager/shared.ts
|
|
43211
43731
|
import { readFileSync as readFileSync13 } from "fs";
|
|
@@ -43239,7 +43759,7 @@ function loadJsonArg2(args, flag = "json") {
|
|
|
43239
43759
|
}
|
|
43240
43760
|
}
|
|
43241
43761
|
var RETRYABLE_CODES2 = /* @__PURE__ */ new Set(["RATE_LIMITED", "INTERNAL_ERROR", "NETWORK_ERROR", "TIMEOUT"]);
|
|
43242
|
-
function
|
|
43762
|
+
function handleError5(err) {
|
|
43243
43763
|
if (err instanceof ApiError) {
|
|
43244
43764
|
writeJsonEnvelope({
|
|
43245
43765
|
ok: false,
|
|
@@ -43269,7 +43789,7 @@ async function stageOp4(op) {
|
|
|
43269
43789
|
const data = await apiPost("/api/tag-manager/draft/stage", { chatId, op });
|
|
43270
43790
|
writeJsonEnvelope({ ok: true, data, hints: STAGE_HINTS2 });
|
|
43271
43791
|
} catch (err) {
|
|
43272
|
-
|
|
43792
|
+
handleError5(err);
|
|
43273
43793
|
}
|
|
43274
43794
|
}
|
|
43275
43795
|
async function draftAction3(path39, body, chat) {
|
|
@@ -43279,7 +43799,7 @@ async function draftAction3(path39, body, chat) {
|
|
|
43279
43799
|
writeJsonEnvelope({ ok: true, data });
|
|
43280
43800
|
return data;
|
|
43281
43801
|
} catch (err) {
|
|
43282
|
-
|
|
43802
|
+
handleError5(err);
|
|
43283
43803
|
}
|
|
43284
43804
|
}
|
|
43285
43805
|
function renderDraft2(response) {
|
|
@@ -43315,7 +43835,7 @@ async function draftList2(json, chat) {
|
|
|
43315
43835
|
process.stdout.write(`${renderDraft2(data)}
|
|
43316
43836
|
`);
|
|
43317
43837
|
} catch (err) {
|
|
43318
|
-
|
|
43838
|
+
handleError5(err);
|
|
43319
43839
|
}
|
|
43320
43840
|
}
|
|
43321
43841
|
|
|
@@ -43328,13 +43848,13 @@ registerSchema({
|
|
|
43328
43848
|
chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
|
|
43329
43849
|
}
|
|
43330
43850
|
});
|
|
43331
|
-
var draftCommand4 =
|
|
43851
|
+
var draftCommand4 = defineCommand193({
|
|
43332
43852
|
meta: {
|
|
43333
43853
|
name: "draft",
|
|
43334
43854
|
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."
|
|
43335
43855
|
},
|
|
43336
43856
|
subCommands: {
|
|
43337
|
-
list:
|
|
43857
|
+
list: defineCommand193({
|
|
43338
43858
|
meta: {
|
|
43339
43859
|
name: "list",
|
|
43340
43860
|
description: "Review everything staged on this chat (--json for the raw envelope)"
|
|
@@ -43347,7 +43867,7 @@ var draftCommand4 = defineCommand192({
|
|
|
43347
43867
|
await draftList2(args.json === true, args.chat);
|
|
43348
43868
|
}
|
|
43349
43869
|
}),
|
|
43350
|
-
show:
|
|
43870
|
+
show: defineCommand193({
|
|
43351
43871
|
meta: {
|
|
43352
43872
|
name: "show",
|
|
43353
43873
|
description: "Print the full staged payload for one change \u2014 the receipt to verify it looks right before publish (never truncated)."
|
|
@@ -43364,7 +43884,7 @@ var draftCommand4 = defineCommand192({
|
|
|
43364
43884
|
);
|
|
43365
43885
|
}
|
|
43366
43886
|
}),
|
|
43367
|
-
amend:
|
|
43887
|
+
amend: defineCommand193({
|
|
43368
43888
|
meta: {
|
|
43369
43889
|
name: "amend",
|
|
43370
43890
|
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."
|
|
@@ -43381,7 +43901,7 @@ var draftCommand4 = defineCommand192({
|
|
|
43381
43901
|
});
|
|
43382
43902
|
}
|
|
43383
43903
|
}),
|
|
43384
|
-
remove:
|
|
43904
|
+
remove: defineCommand193({
|
|
43385
43905
|
meta: { name: "remove", description: "Remove one staged change (cascades to anything depending on it)" },
|
|
43386
43906
|
args: { ref: { type: "positional", description: "Staged ref (gtm_temp_*) or target", required: false } },
|
|
43387
43907
|
run: async ({ args }) => {
|
|
@@ -43390,7 +43910,7 @@ var draftCommand4 = defineCommand192({
|
|
|
43390
43910
|
});
|
|
43391
43911
|
}
|
|
43392
43912
|
}),
|
|
43393
|
-
clear:
|
|
43913
|
+
clear: defineCommand193({
|
|
43394
43914
|
meta: { name: "clear", description: "Discard all Tag Manager changes staged on this chat" },
|
|
43395
43915
|
run: async () => {
|
|
43396
43916
|
await draftAction3("/api/tag-manager/draft/clear", {});
|
|
@@ -43400,7 +43920,7 @@ var draftCommand4 = defineCommand192({
|
|
|
43400
43920
|
});
|
|
43401
43921
|
|
|
43402
43922
|
// src/commands/tag-manager/read.ts
|
|
43403
|
-
import { defineCommand as
|
|
43923
|
+
import { defineCommand as defineCommand194 } from "citty";
|
|
43404
43924
|
registerSchema({
|
|
43405
43925
|
command: "tagManager.containers",
|
|
43406
43926
|
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.",
|
|
@@ -43441,7 +43961,7 @@ function containersHints(containers) {
|
|
|
43441
43961
|
}))
|
|
43442
43962
|
});
|
|
43443
43963
|
}
|
|
43444
|
-
var containersCommand =
|
|
43964
|
+
var containersCommand = defineCommand194({
|
|
43445
43965
|
meta: {
|
|
43446
43966
|
name: "containers",
|
|
43447
43967
|
description: `List Tag Manager containers reachable by this company's connection.
|
|
@@ -43454,11 +43974,11 @@ Start here:
|
|
|
43454
43974
|
const data = await apiGet("/api/tag-manager/containers");
|
|
43455
43975
|
writeJsonEnvelope({ ok: true, data, hints: containersHints(data.containers) });
|
|
43456
43976
|
} catch (err) {
|
|
43457
|
-
|
|
43977
|
+
handleError5(err);
|
|
43458
43978
|
}
|
|
43459
43979
|
}
|
|
43460
43980
|
});
|
|
43461
|
-
var readCommand =
|
|
43981
|
+
var readCommand = defineCommand194({
|
|
43462
43982
|
meta: {
|
|
43463
43983
|
name: "read",
|
|
43464
43984
|
description: `Read the current contents of the Tag Manager container \u2014 always do this before staging changes.
|
|
@@ -43494,13 +44014,13 @@ Examples:
|
|
|
43494
44014
|
);
|
|
43495
44015
|
writeJsonEnvelope({ ok: true, data, hints });
|
|
43496
44016
|
} catch (err) {
|
|
43497
|
-
|
|
44017
|
+
handleError5(err);
|
|
43498
44018
|
}
|
|
43499
44019
|
}
|
|
43500
44020
|
});
|
|
43501
44021
|
|
|
43502
44022
|
// src/commands/tag-manager/write-commands.ts
|
|
43503
|
-
import { defineCommand as
|
|
44023
|
+
import { defineCommand as defineCommand195 } from "citty";
|
|
43504
44024
|
var CONTAINER_ARG_DESCRIPTION = "Numeric container id (optional only when one container is connected \u2014 run `baker tag-manager containers`)";
|
|
43505
44025
|
var ENTITIES = [
|
|
43506
44026
|
{
|
|
@@ -43556,10 +44076,10 @@ for (const { entity, noun, createHint } of ENTITIES) {
|
|
|
43556
44076
|
});
|
|
43557
44077
|
}
|
|
43558
44078
|
function entityCommand(entity, noun, example) {
|
|
43559
|
-
return
|
|
44079
|
+
return defineCommand195({
|
|
43560
44080
|
meta: { name: entity, description: `Stage ${noun} changes on this chat's Tag Manager draft` },
|
|
43561
44081
|
subCommands: {
|
|
43562
|
-
create:
|
|
44082
|
+
create: defineCommand195({
|
|
43563
44083
|
meta: {
|
|
43564
44084
|
name: "create",
|
|
43565
44085
|
description: `Stage a new ${noun}
|
|
@@ -43581,7 +44101,7 @@ Examples:
|
|
|
43581
44101
|
});
|
|
43582
44102
|
}
|
|
43583
44103
|
}),
|
|
43584
|
-
update:
|
|
44104
|
+
update: defineCommand195({
|
|
43585
44105
|
meta: {
|
|
43586
44106
|
name: "update",
|
|
43587
44107
|
description: `Stage an update to an existing ${noun} (pass its id or path)`
|
|
@@ -43601,7 +44121,7 @@ Examples:
|
|
|
43601
44121
|
});
|
|
43602
44122
|
}
|
|
43603
44123
|
}),
|
|
43604
|
-
delete:
|
|
44124
|
+
delete: defineCommand195({
|
|
43605
44125
|
meta: { name: "delete", description: `Stage the deletion of a ${noun} (pass its id or path)` },
|
|
43606
44126
|
args: {
|
|
43607
44127
|
id: { type: "positional", description: `${noun} id or path`, required: false },
|
|
@@ -43642,7 +44162,7 @@ function builtinTypes(args) {
|
|
|
43642
44162
|
}
|
|
43643
44163
|
return raw.split(",").map((entry) => entry.trim());
|
|
43644
44164
|
}
|
|
43645
|
-
var builtinCommand =
|
|
44165
|
+
var builtinCommand = defineCommand195({
|
|
43646
44166
|
meta: {
|
|
43647
44167
|
name: "builtin",
|
|
43648
44168
|
description: `Enable or disable built-in variables
|
|
@@ -43652,7 +44172,7 @@ Examples:
|
|
|
43652
44172
|
baker tag-manager builtin disable --types formId`
|
|
43653
44173
|
},
|
|
43654
44174
|
subCommands: {
|
|
43655
|
-
enable:
|
|
44175
|
+
enable: defineCommand195({
|
|
43656
44176
|
meta: { name: "enable", description: "Stage enabling built-in variables" },
|
|
43657
44177
|
args: {
|
|
43658
44178
|
types: { type: "string", description: "Comma-separated types", required: false },
|
|
@@ -43666,7 +44186,7 @@ Examples:
|
|
|
43666
44186
|
});
|
|
43667
44187
|
}
|
|
43668
44188
|
}),
|
|
43669
|
-
disable:
|
|
44189
|
+
disable: defineCommand195({
|
|
43670
44190
|
meta: { name: "disable", description: "Stage disabling built-in variables" },
|
|
43671
44191
|
args: {
|
|
43672
44192
|
types: { type: "string", description: "Comma-separated types", required: false },
|
|
@@ -43684,7 +44204,7 @@ Examples:
|
|
|
43684
44204
|
});
|
|
43685
44205
|
|
|
43686
44206
|
// src/commands/tag-manager/index.ts
|
|
43687
|
-
var tagManagerCommand =
|
|
44207
|
+
var tagManagerCommand = defineCommand196({
|
|
43688
44208
|
meta: {
|
|
43689
44209
|
name: "tag-manager",
|
|
43690
44210
|
description: `Read and change what lives inside the client's Google Tag Manager container \u2014 tags, triggers, variables, folders and built-in variables.
|
|
@@ -43721,7 +44241,7 @@ Full guide: __tooling__/docs/tools/baker/tag-manager.md`
|
|
|
43721
44241
|
});
|
|
43722
44242
|
|
|
43723
44243
|
// src/commands/tags/index.ts
|
|
43724
|
-
import { defineCommand as
|
|
44244
|
+
import { defineCommand as defineCommand197 } from "citty";
|
|
43725
44245
|
|
|
43726
44246
|
// src/commands/tags/shared.ts
|
|
43727
44247
|
function failApi3(err) {
|
|
@@ -43790,7 +44310,7 @@ async function listTags(json) {
|
|
|
43790
44310
|
var listArgs9 = {
|
|
43791
44311
|
json: { type: "boolean", description: "Print the raw JSON envelope instead of the readable list" }
|
|
43792
44312
|
};
|
|
43793
|
-
var listCommand17 =
|
|
44313
|
+
var listCommand17 = defineCommand197({
|
|
43794
44314
|
meta: {
|
|
43795
44315
|
name: "list",
|
|
43796
44316
|
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"
|
|
@@ -43809,7 +44329,7 @@ async function listDraft3(chat) {
|
|
|
43809
44329
|
failApi3(err);
|
|
43810
44330
|
}
|
|
43811
44331
|
}
|
|
43812
|
-
var draftCommand5 =
|
|
44332
|
+
var draftCommand5 = defineCommand197({
|
|
43813
44333
|
meta: {
|
|
43814
44334
|
name: "draft",
|
|
43815
44335
|
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."
|
|
@@ -43819,7 +44339,7 @@ var draftCommand5 = defineCommand196({
|
|
|
43819
44339
|
await listDraft3(args.chat);
|
|
43820
44340
|
}
|
|
43821
44341
|
});
|
|
43822
|
-
var
|
|
44342
|
+
var tagsCommand4 = defineCommand197({
|
|
43823
44343
|
meta: {
|
|
43824
44344
|
name: "tags",
|
|
43825
44345
|
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.
|
|
@@ -43848,10 +44368,10 @@ Full guide: __tooling__/docs/tools/baker/tags.md`
|
|
|
43848
44368
|
});
|
|
43849
44369
|
|
|
43850
44370
|
// src/commands/testimonials/index.ts
|
|
43851
|
-
import { defineCommand as
|
|
44371
|
+
import { defineCommand as defineCommand201 } from "citty";
|
|
43852
44372
|
|
|
43853
44373
|
// src/commands/testimonials/get.ts
|
|
43854
|
-
import { defineCommand as
|
|
44374
|
+
import { defineCommand as defineCommand198 } from "citty";
|
|
43855
44375
|
registerSchema({
|
|
43856
44376
|
command: "testimonials.get",
|
|
43857
44377
|
description: "Get a single testimonial by ID",
|
|
@@ -43859,7 +44379,7 @@ registerSchema({
|
|
|
43859
44379
|
id: { type: "string", description: "Testimonial ID", required: true }
|
|
43860
44380
|
}
|
|
43861
44381
|
});
|
|
43862
|
-
var getCommand6 =
|
|
44382
|
+
var getCommand6 = defineCommand198({
|
|
43863
44383
|
meta: { name: "get", description: "Get a single testimonial by ID. Example: baker testimonials get j571abc123" },
|
|
43864
44384
|
args: {
|
|
43865
44385
|
id: { type: "positional", description: "Testimonial ID", required: false },
|
|
@@ -43896,7 +44416,7 @@ var getCommand6 = defineCommand197({
|
|
|
43896
44416
|
});
|
|
43897
44417
|
|
|
43898
44418
|
// src/commands/testimonials/list.ts
|
|
43899
|
-
import { defineCommand as
|
|
44419
|
+
import { defineCommand as defineCommand199 } from "citty";
|
|
43900
44420
|
|
|
43901
44421
|
// src/commands/testimonials/emptyCorpusHints.ts
|
|
43902
44422
|
function resolveEmptyReason({
|
|
@@ -44031,7 +44551,7 @@ function buildListParams(args) {
|
|
|
44031
44551
|
}
|
|
44032
44552
|
return params;
|
|
44033
44553
|
}
|
|
44034
|
-
var listCommand18 =
|
|
44554
|
+
var listCommand18 = defineCommand199({
|
|
44035
44555
|
meta: {
|
|
44036
44556
|
name: "list",
|
|
44037
44557
|
description: "List testimonials with optional filters. Example: baker testimonials list --source google --sentiment positive"
|
|
@@ -44083,7 +44603,7 @@ var listCommand18 = defineCommand198({
|
|
|
44083
44603
|
});
|
|
44084
44604
|
|
|
44085
44605
|
// src/commands/testimonials/search.ts
|
|
44086
|
-
import { defineCommand as
|
|
44606
|
+
import { defineCommand as defineCommand200 } from "citty";
|
|
44087
44607
|
var FILTER_FLAGS2 = ["source", "rating-min", "rating-max", "status", "sentiment", "language", "tags"];
|
|
44088
44608
|
function languageBiasHint(results, requestedLanguage) {
|
|
44089
44609
|
if (requestedLanguage) {
|
|
@@ -44162,7 +44682,7 @@ function buildSearchRequest(query, args) {
|
|
|
44162
44682
|
}
|
|
44163
44683
|
return body;
|
|
44164
44684
|
}
|
|
44165
|
-
var searchCommand3 =
|
|
44685
|
+
var searchCommand3 = defineCommand200({
|
|
44166
44686
|
meta: {
|
|
44167
44687
|
name: "search",
|
|
44168
44688
|
description: "Semantic search testimonials by text query. Uses hybrid BM25 + vector + reranking. Example: baker testimonials search 'great service' --rating-min 4"
|
|
@@ -44223,10 +44743,10 @@ var searchCommand3 = defineCommand199({
|
|
|
44223
44743
|
});
|
|
44224
44744
|
|
|
44225
44745
|
// src/commands/testimonials/tags.ts
|
|
44226
|
-
var
|
|
44746
|
+
var tagsCommand5 = makeTagsCommand("testimonials", "testimonial", "/api/testimonials/tags");
|
|
44227
44747
|
|
|
44228
44748
|
// src/commands/testimonials/index.ts
|
|
44229
|
-
var testimonialsCommand =
|
|
44749
|
+
var testimonialsCommand = defineCommand201({
|
|
44230
44750
|
meta: {
|
|
44231
44751
|
name: "testimonials",
|
|
44232
44752
|
description: `Find and browse testimonials in Baker. Subcommands: search, get, list, tags.
|
|
@@ -44243,15 +44763,15 @@ Full guide: __tooling__/docs/tools/baker/testimonials.md`
|
|
|
44243
44763
|
get: getCommand6,
|
|
44244
44764
|
search: searchCommand3,
|
|
44245
44765
|
list: listCommand18,
|
|
44246
|
-
tags:
|
|
44766
|
+
tags: tagsCommand5
|
|
44247
44767
|
}
|
|
44248
44768
|
});
|
|
44249
44769
|
|
|
44250
44770
|
// src/commands/videos/index.ts
|
|
44251
|
-
import { defineCommand as
|
|
44771
|
+
import { defineCommand as defineCommand208 } from "citty";
|
|
44252
44772
|
|
|
44253
44773
|
// src/commands/videos/delete.ts
|
|
44254
|
-
import { defineCommand as
|
|
44774
|
+
import { defineCommand as defineCommand202 } from "citty";
|
|
44255
44775
|
registerSchema({
|
|
44256
44776
|
command: "videos.delete",
|
|
44257
44777
|
description: "Delete a video by ID",
|
|
@@ -44265,7 +44785,7 @@ registerSchema({
|
|
|
44265
44785
|
}
|
|
44266
44786
|
}
|
|
44267
44787
|
});
|
|
44268
|
-
var deleteCommand4 =
|
|
44788
|
+
var deleteCommand4 = defineCommand202({
|
|
44269
44789
|
meta: {
|
|
44270
44790
|
name: "delete",
|
|
44271
44791
|
description: "Delete a video by ID. Use --dry-run to preview. Example: baker videos delete j571abc123 --dry-run"
|
|
@@ -44306,7 +44826,7 @@ var deleteCommand4 = defineCommand201({
|
|
|
44306
44826
|
});
|
|
44307
44827
|
|
|
44308
44828
|
// src/commands/videos/get.ts
|
|
44309
|
-
import { defineCommand as
|
|
44829
|
+
import { defineCommand as defineCommand203 } from "citty";
|
|
44310
44830
|
registerSchema({
|
|
44311
44831
|
command: "videos.get",
|
|
44312
44832
|
description: "Get a single video by ID",
|
|
@@ -44314,7 +44834,7 @@ registerSchema({
|
|
|
44314
44834
|
id: { type: "string", description: "Video ID", required: true }
|
|
44315
44835
|
}
|
|
44316
44836
|
});
|
|
44317
|
-
var getCommand7 =
|
|
44837
|
+
var getCommand7 = defineCommand203({
|
|
44318
44838
|
meta: { name: "get", description: "Get a single video by ID. Example: baker videos get j571abc123" },
|
|
44319
44839
|
args: {
|
|
44320
44840
|
id: { type: "positional", description: "Video ID", required: false },
|
|
@@ -44351,7 +44871,7 @@ var getCommand7 = defineCommand202({
|
|
|
44351
44871
|
});
|
|
44352
44872
|
|
|
44353
44873
|
// src/commands/videos/group.ts
|
|
44354
|
-
import { defineCommand as
|
|
44874
|
+
import { defineCommand as defineCommand204 } from "citty";
|
|
44355
44875
|
registerSchema({
|
|
44356
44876
|
command: "videos.group",
|
|
44357
44877
|
description: "List every clip and image that arrived in the same set as this video (carousel slides, one page)",
|
|
@@ -44360,7 +44880,7 @@ registerSchema({
|
|
|
44360
44880
|
"group-key": { type: "string", description: "The set key directly, when you already have it", required: false }
|
|
44361
44881
|
}
|
|
44362
44882
|
});
|
|
44363
|
-
var groupCommand2 =
|
|
44883
|
+
var groupCommand2 = defineCommand204({
|
|
44364
44884
|
meta: {
|
|
44365
44885
|
name: "group",
|
|
44366
44886
|
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>"
|
|
@@ -44383,7 +44903,7 @@ var groupCommand2 = defineCommand203({
|
|
|
44383
44903
|
import { mkdtemp as mkdtemp2, rm as rm7, stat as stat7 } from "fs/promises";
|
|
44384
44904
|
import { tmpdir as tmpdir3 } from "os";
|
|
44385
44905
|
import path38 from "path";
|
|
44386
|
-
import { defineCommand as
|
|
44906
|
+
import { defineCommand as defineCommand205 } from "citty";
|
|
44387
44907
|
|
|
44388
44908
|
// src/lib/streamUpload.ts
|
|
44389
44909
|
import { createHash as createHash2 } from "crypto";
|
|
@@ -44547,7 +45067,7 @@ registerSchema({
|
|
|
44547
45067
|
"dry-run": { type: "boolean", description: "Preview the operation without executing", required: false }
|
|
44548
45068
|
}
|
|
44549
45069
|
});
|
|
44550
|
-
var ingestCommand2 =
|
|
45070
|
+
var ingestCommand2 = defineCommand205({
|
|
44551
45071
|
meta: {
|
|
44552
45072
|
name: "ingest",
|
|
44553
45073
|
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"
|
|
@@ -44809,7 +45329,7 @@ async function uploadToAssetStore(filePath, sizeBytes) {
|
|
|
44809
45329
|
}
|
|
44810
45330
|
|
|
44811
45331
|
// src/commands/videos/search.ts
|
|
44812
|
-
import { defineCommand as
|
|
45332
|
+
import { defineCommand as defineCommand206 } from "citty";
|
|
44813
45333
|
registerSchema({
|
|
44814
45334
|
command: "videos.search",
|
|
44815
45335
|
description: "Search videos by text query. Only returns ready videos.",
|
|
@@ -44819,7 +45339,7 @@ registerSchema({
|
|
|
44819
45339
|
tags: { type: "string", description: "Comma-separated tags to filter by", required: false }
|
|
44820
45340
|
}
|
|
44821
45341
|
});
|
|
44822
|
-
var searchCommand4 =
|
|
45342
|
+
var searchCommand4 = defineCommand206({
|
|
44823
45343
|
meta: {
|
|
44824
45344
|
name: "search",
|
|
44825
45345
|
description: "Semantic search videos by text query. Uses hybrid BM25 + vector + reranking. Example: baker videos search 'product demo' --tags tutorial"
|
|
@@ -44866,12 +45386,12 @@ var searchCommand4 = defineCommand205({
|
|
|
44866
45386
|
});
|
|
44867
45387
|
|
|
44868
45388
|
// src/commands/videos/tags.ts
|
|
44869
|
-
var
|
|
45389
|
+
var tagsCommand6 = makeTagsCommand("videos", "video", "/api/videos/tags");
|
|
44870
45390
|
|
|
44871
45391
|
// src/commands/videos/upload.ts
|
|
44872
45392
|
import { readFile as readFile25, stat as stat8 } from "fs/promises";
|
|
44873
45393
|
import { basename as basename3, extname as extname4 } from "path";
|
|
44874
|
-
import { defineCommand as
|
|
45394
|
+
import { defineCommand as defineCommand207 } from "citty";
|
|
44875
45395
|
var MIME_MAP = {
|
|
44876
45396
|
".mp4": "video/mp4",
|
|
44877
45397
|
".mov": "video/quicktime",
|
|
@@ -44913,7 +45433,7 @@ function detectContentType(filePath) {
|
|
|
44913
45433
|
function isRemoteUrl3(value) {
|
|
44914
45434
|
return /^https?:\/\//i.test(value);
|
|
44915
45435
|
}
|
|
44916
|
-
var uploadCommand2 =
|
|
45436
|
+
var uploadCommand2 = defineCommand207({
|
|
44917
45437
|
meta: {
|
|
44918
45438
|
name: "upload",
|
|
44919
45439
|
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"
|
|
@@ -44997,7 +45517,7 @@ var uploadCommand2 = defineCommand206({
|
|
|
44997
45517
|
});
|
|
44998
45518
|
|
|
44999
45519
|
// src/commands/videos/index.ts
|
|
45000
|
-
var videosCommand =
|
|
45520
|
+
var videosCommand = defineCommand208({
|
|
45001
45521
|
meta: {
|
|
45002
45522
|
name: "videos",
|
|
45003
45523
|
description: `Find and manage videos in Baker. Subcommands: search, get, upload, ingest, delete, tags.
|
|
@@ -45019,15 +45539,15 @@ Full guide: __tooling__/docs/tools/baker/videos.md`
|
|
|
45019
45539
|
upload: uploadCommand2,
|
|
45020
45540
|
ingest: ingestCommand2,
|
|
45021
45541
|
delete: deleteCommand4,
|
|
45022
|
-
tags:
|
|
45542
|
+
tags: tagsCommand6
|
|
45023
45543
|
}
|
|
45024
45544
|
});
|
|
45025
45545
|
|
|
45026
45546
|
// src/commands/winning-ads/index.ts
|
|
45027
|
-
import { defineCommand as
|
|
45547
|
+
import { defineCommand as defineCommand221 } from "citty";
|
|
45028
45548
|
|
|
45029
45549
|
// src/commands/winning-ads/advertisers.ts
|
|
45030
|
-
import { defineCommand as
|
|
45550
|
+
import { defineCommand as defineCommand209 } from "citty";
|
|
45031
45551
|
|
|
45032
45552
|
// src/commands/winning-ads/shared.ts
|
|
45033
45553
|
function splitList2(value) {
|
|
@@ -45080,7 +45600,7 @@ function advertiserNormalizer(record, full) {
|
|
|
45080
45600
|
last_synced_at: record.last_synced_at ?? null
|
|
45081
45601
|
};
|
|
45082
45602
|
}
|
|
45083
|
-
var advertisersCommand2 =
|
|
45603
|
+
var advertisersCommand2 = defineCommand209({
|
|
45084
45604
|
meta: {
|
|
45085
45605
|
name: "advertisers",
|
|
45086
45606
|
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'
|
|
@@ -45138,7 +45658,7 @@ var advertisersCommand2 = defineCommand208({
|
|
|
45138
45658
|
});
|
|
45139
45659
|
|
|
45140
45660
|
// src/commands/winning-ads/brief.ts
|
|
45141
|
-
import { defineCommand as
|
|
45661
|
+
import { defineCommand as defineCommand210 } from "citty";
|
|
45142
45662
|
registerSchema({
|
|
45143
45663
|
command: "winning-ads.brief",
|
|
45144
45664
|
description: "Generate a creative brief grounded in strategically-similar winning ads. Optionally describe the target creative with --dna (JSON) and steer with --notes.",
|
|
@@ -45184,7 +45704,7 @@ function parseDna(raw) {
|
|
|
45184
45704
|
}
|
|
45185
45705
|
return parsed;
|
|
45186
45706
|
}
|
|
45187
|
-
var briefCommand =
|
|
45707
|
+
var briefCommand = defineCommand210({
|
|
45188
45708
|
meta: {
|
|
45189
45709
|
name: "brief",
|
|
45190
45710
|
description: `Generate a creative brief from winning references. Example: baker winning-ads brief --dna '{"angle":"cost savings"}' --notes "B2B, LinkedIn video" --k 8`
|
|
@@ -45220,7 +45740,7 @@ var briefCommand = defineCommand209({
|
|
|
45220
45740
|
});
|
|
45221
45741
|
|
|
45222
45742
|
// src/commands/winning-ads/content.ts
|
|
45223
|
-
import { defineCommand as
|
|
45743
|
+
import { defineCommand as defineCommand211 } from "citty";
|
|
45224
45744
|
registerSchema({
|
|
45225
45745
|
command: "winning-ads.content",
|
|
45226
45746
|
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.",
|
|
@@ -45233,7 +45753,7 @@ registerSchema({
|
|
|
45233
45753
|
}
|
|
45234
45754
|
}
|
|
45235
45755
|
});
|
|
45236
|
-
var contentCommand =
|
|
45756
|
+
var contentCommand = defineCommand211({
|
|
45237
45757
|
meta: {
|
|
45238
45758
|
name: "content",
|
|
45239
45759
|
description: "Read the transcript + on-screen text + copy of one winning ad. Example: baker winning-ads content adg_123 --platform meta --full --output md"
|
|
@@ -45282,7 +45802,7 @@ var contentCommand = defineCommand210({
|
|
|
45282
45802
|
});
|
|
45283
45803
|
|
|
45284
45804
|
// src/commands/winning-ads/feed.ts
|
|
45285
|
-
import { defineCommand as
|
|
45805
|
+
import { defineCommand as defineCommand212 } from "citty";
|
|
45286
45806
|
function buildFeedParams(input) {
|
|
45287
45807
|
const params = {};
|
|
45288
45808
|
const advertiser = splitList2(input.advertiser);
|
|
@@ -45334,7 +45854,7 @@ registerSchema({
|
|
|
45334
45854
|
format: { type: "string", description: "Comma-separated formats to include (e.g. static,video)", required: false }
|
|
45335
45855
|
}
|
|
45336
45856
|
});
|
|
45337
|
-
var feedCommand =
|
|
45857
|
+
var feedCommand = defineCommand212({
|
|
45338
45858
|
meta: {
|
|
45339
45859
|
name: "feed",
|
|
45340
45860
|
description: "Winners across every brand you follow (browse, then trim per advertiser). Example: baker winning-ads feed --per-advertiser 5 --output md"
|
|
@@ -45419,7 +45939,7 @@ var feedCommand = defineCommand211({
|
|
|
45419
45939
|
});
|
|
45420
45940
|
|
|
45421
45941
|
// src/commands/winning-ads/follow.ts
|
|
45422
|
-
import { defineCommand as
|
|
45942
|
+
import { defineCommand as defineCommand213 } from "citty";
|
|
45423
45943
|
var PLATFORMS = ["meta", "linkedin"];
|
|
45424
45944
|
registerSchema({
|
|
45425
45945
|
command: "winning-ads.follow",
|
|
@@ -45434,7 +45954,7 @@ registerSchema({
|
|
|
45434
45954
|
label: { type: "string", description: "Optional display label (defaults to the resolved name)", required: false }
|
|
45435
45955
|
}
|
|
45436
45956
|
});
|
|
45437
|
-
var followCommand =
|
|
45957
|
+
var followCommand = defineCommand213({
|
|
45438
45958
|
meta: {
|
|
45439
45959
|
name: "follow",
|
|
45440
45960
|
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'
|
|
@@ -45481,7 +46001,7 @@ var followCommand = defineCommand212({
|
|
|
45481
46001
|
});
|
|
45482
46002
|
|
|
45483
46003
|
// src/commands/winning-ads/follow-competitors.ts
|
|
45484
|
-
import { defineCommand as
|
|
46004
|
+
import { defineCommand as defineCommand214 } from "citty";
|
|
45485
46005
|
var PLATFORMS2 = ["meta", "linkedin"];
|
|
45486
46006
|
var BATCH_TIMEOUT_MS = 3e5;
|
|
45487
46007
|
function buildFollowBatchBody(input) {
|
|
@@ -45514,7 +46034,7 @@ registerSchema({
|
|
|
45514
46034
|
}
|
|
45515
46035
|
}
|
|
45516
46036
|
});
|
|
45517
|
-
var followCompetitorsCommand =
|
|
46037
|
+
var followCompetitorsCommand = defineCommand214({
|
|
45518
46038
|
meta: {
|
|
45519
46039
|
name: "follow-competitors",
|
|
45520
46040
|
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"'
|
|
@@ -45589,7 +46109,7 @@ var followCompetitorsCommand = defineCommand213({
|
|
|
45589
46109
|
});
|
|
45590
46110
|
|
|
45591
46111
|
// src/commands/winning-ads/following.ts
|
|
45592
|
-
import { defineCommand as
|
|
46112
|
+
import { defineCommand as defineCommand215 } from "citty";
|
|
45593
46113
|
registerSchema({
|
|
45594
46114
|
command: "winning-ads.following",
|
|
45595
46115
|
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.",
|
|
@@ -45643,7 +46163,7 @@ function followingNormalizer(record, full) {
|
|
|
45643
46163
|
platforms: Array.isArray(record.platforms) ? record.platforms : []
|
|
45644
46164
|
};
|
|
45645
46165
|
}
|
|
45646
|
-
var followingCommand =
|
|
46166
|
+
var followingCommand = defineCommand215({
|
|
45647
46167
|
meta: {
|
|
45648
46168
|
name: "following",
|
|
45649
46169
|
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"
|
|
@@ -45679,7 +46199,7 @@ var followingCommand = defineCommand214({
|
|
|
45679
46199
|
});
|
|
45680
46200
|
|
|
45681
46201
|
// src/commands/winning-ads/patterns.ts
|
|
45682
|
-
import { defineCommand as
|
|
46202
|
+
import { defineCommand as defineCommand216 } from "citty";
|
|
45683
46203
|
registerSchema({
|
|
45684
46204
|
command: "winning-ads.patterns",
|
|
45685
46205
|
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.",
|
|
@@ -45718,7 +46238,7 @@ function discriminatorRow(record) {
|
|
|
45718
46238
|
top_values_duds: Array.isArray(record.top_values_b) ? record.top_values_b.join(", ") : ""
|
|
45719
46239
|
};
|
|
45720
46240
|
}
|
|
45721
|
-
var patternsCommand =
|
|
46241
|
+
var patternsCommand = defineCommand216({
|
|
45722
46242
|
meta: {
|
|
45723
46243
|
name: "patterns",
|
|
45724
46244
|
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"
|
|
@@ -45774,7 +46294,7 @@ var patternsCommand = defineCommand215({
|
|
|
45774
46294
|
});
|
|
45775
46295
|
|
|
45776
46296
|
// src/commands/winning-ads/search.ts
|
|
45777
|
-
import { defineCommand as
|
|
46297
|
+
import { defineCommand as defineCommand217 } from "citty";
|
|
45778
46298
|
registerSchema({
|
|
45779
46299
|
command: "winning-ads.search",
|
|
45780
46300
|
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.",
|
|
@@ -45882,7 +46402,7 @@ function buildSearchBody2(args) {
|
|
|
45882
46402
|
}
|
|
45883
46403
|
return body;
|
|
45884
46404
|
}
|
|
45885
|
-
var searchCommand5 =
|
|
46405
|
+
var searchCommand5 = defineCommand217({
|
|
45886
46406
|
meta: {
|
|
45887
46407
|
name: "search",
|
|
45888
46408
|
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"
|
|
@@ -45997,7 +46517,7 @@ var searchCommand5 = defineCommand216({
|
|
|
45997
46517
|
});
|
|
45998
46518
|
|
|
45999
46519
|
// src/commands/winning-ads/seeds.ts
|
|
46000
|
-
import { defineCommand as
|
|
46520
|
+
import { defineCommand as defineCommand218 } from "citty";
|
|
46001
46521
|
function leanRow(r) {
|
|
46002
46522
|
return {
|
|
46003
46523
|
key: r.key,
|
|
@@ -46025,7 +46545,7 @@ function makeSeedCommand(opts) {
|
|
|
46025
46545
|
limit: { type: "number", description: "Max keys 1-100 (default 20)", required: false, default: 20 }
|
|
46026
46546
|
}
|
|
46027
46547
|
});
|
|
46028
|
-
return
|
|
46548
|
+
return defineCommand218({
|
|
46029
46549
|
meta: { name: opts.name, description: opts.description },
|
|
46030
46550
|
args: {
|
|
46031
46551
|
platform: { type: "string", description: "Single platform to segment on", required: false },
|
|
@@ -46074,7 +46594,7 @@ var formatsCommand = makeSeedCommand({
|
|
|
46074
46594
|
});
|
|
46075
46595
|
|
|
46076
46596
|
// src/commands/winning-ads/unfollow.ts
|
|
46077
|
-
import { defineCommand as
|
|
46597
|
+
import { defineCommand as defineCommand219 } from "citty";
|
|
46078
46598
|
registerSchema({
|
|
46079
46599
|
command: "winning-ads.unfollow",
|
|
46080
46600
|
description: "Stop following a brand \u2014 removes it from your ad-dna library by advertiser id.",
|
|
@@ -46082,7 +46602,7 @@ registerSchema({
|
|
|
46082
46602
|
advertiser: { type: "string", description: "Advertiser id to unfollow", required: true }
|
|
46083
46603
|
}
|
|
46084
46604
|
});
|
|
46085
|
-
var unfollowCommand =
|
|
46605
|
+
var unfollowCommand = defineCommand219({
|
|
46086
46606
|
meta: {
|
|
46087
46607
|
name: "unfollow",
|
|
46088
46608
|
description: "Stop following a brand by advertiser id. Example: baker winning-ads unfollow adv_123"
|
|
@@ -46103,7 +46623,7 @@ var unfollowCommand = defineCommand218({
|
|
|
46103
46623
|
});
|
|
46104
46624
|
|
|
46105
46625
|
// src/commands/winning-ads/winners.ts
|
|
46106
|
-
import { defineCommand as
|
|
46626
|
+
import { defineCommand as defineCommand220 } from "citty";
|
|
46107
46627
|
registerSchema({
|
|
46108
46628
|
command: "winning-ads.winners",
|
|
46109
46629
|
description: "Top winning ads for one advertiser id (from `advertisers` or `following`). Returns lean winner cards; add --full for DNA + longevity.",
|
|
@@ -46113,7 +46633,7 @@ registerSchema({
|
|
|
46113
46633
|
platform: { type: "string", description: "Filter to a single platform: meta|linkedin", required: false }
|
|
46114
46634
|
}
|
|
46115
46635
|
});
|
|
46116
|
-
var winnersCommand =
|
|
46636
|
+
var winnersCommand = defineCommand220({
|
|
46117
46637
|
meta: {
|
|
46118
46638
|
name: "winners",
|
|
46119
46639
|
description: "Top winning ads for a specific advertiser id. Example: baker winning-ads winners adv_123 --top 15 --output md"
|
|
@@ -46163,7 +46683,7 @@ var winnersCommand = defineCommand219({
|
|
|
46163
46683
|
});
|
|
46164
46684
|
|
|
46165
46685
|
// src/commands/winning-ads/index.ts
|
|
46166
|
-
var winningAdsCommand =
|
|
46686
|
+
var winningAdsCommand = defineCommand221({
|
|
46167
46687
|
meta: {
|
|
46168
46688
|
name: "winning-ads",
|
|
46169
46689
|
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.
|
|
@@ -46401,7 +46921,7 @@ function getCliVersion() {
|
|
|
46401
46921
|
}
|
|
46402
46922
|
|
|
46403
46923
|
// src/cli.ts
|
|
46404
|
-
var main =
|
|
46924
|
+
var main = defineCommand222({
|
|
46405
46925
|
meta: {
|
|
46406
46926
|
name: "baker",
|
|
46407
46927
|
version: getCliVersion(),
|
|
@@ -46419,6 +46939,7 @@ Introspection: Run 'baker schema <command>' to inspect argument schemas.`
|
|
|
46419
46939
|
"scheduled-actions": scheduledActionsCommand,
|
|
46420
46940
|
ads: adsCommand2,
|
|
46421
46941
|
brand: brandCommand,
|
|
46942
|
+
analytics: analyticsCommand2,
|
|
46422
46943
|
ga4: ga4Command,
|
|
46423
46944
|
gsc: gscCommand,
|
|
46424
46945
|
research: researchCommand,
|
|
@@ -46431,7 +46952,7 @@ Introspection: Run 'baker schema <command>' to inspect argument schemas.`
|
|
|
46431
46952
|
videos: videosCommand,
|
|
46432
46953
|
testimonials: testimonialsCommand,
|
|
46433
46954
|
canvas: canvasCommand,
|
|
46434
|
-
tags:
|
|
46955
|
+
tags: tagsCommand4,
|
|
46435
46956
|
"tag-manager": tagManagerCommand,
|
|
46436
46957
|
chats: chatsCommand,
|
|
46437
46958
|
history: historyCommand,
|