@koda-sl/baker-cli 0.95.0 → 0.96.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +29 -3
- package/dist/cli.js +516 -296
- package/dist/cli.js.map +1 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -12,10 +12,10 @@ import {
|
|
|
12
12
|
} from "./chunk-RCPMJKI7.js";
|
|
13
13
|
|
|
14
14
|
// src/cli.ts
|
|
15
|
-
import { defineCommand as
|
|
15
|
+
import { defineCommand as defineCommand148, runMain } from "citty";
|
|
16
16
|
|
|
17
17
|
// src/commands/actions/index.ts
|
|
18
|
-
import { defineCommand as
|
|
18
|
+
import { defineCommand as defineCommand17 } from "citty";
|
|
19
19
|
|
|
20
20
|
// src/commands/actions/claim.ts
|
|
21
21
|
import { defineCommand } from "citty";
|
|
@@ -465,6 +465,13 @@ function generateTempId() {
|
|
|
465
465
|
function isTempId(id) {
|
|
466
466
|
return id.startsWith("temp_");
|
|
467
467
|
}
|
|
468
|
+
function parseTagList(value) {
|
|
469
|
+
if (typeof value !== "string") {
|
|
470
|
+
return void 0;
|
|
471
|
+
}
|
|
472
|
+
const tags = value.split(",").map((t) => t.trim()).filter((t) => t.length > 0);
|
|
473
|
+
return [...new Set(tags)];
|
|
474
|
+
}
|
|
468
475
|
var SCHEDULE_SIGNALS = [
|
|
469
476
|
/\brecurr(?:ing|ence)\b/i,
|
|
470
477
|
/\bcadence\b/i,
|
|
@@ -563,7 +570,7 @@ var completeCommand = defineCommand2({
|
|
|
563
570
|
import { defineCommand as defineCommand3 } from "citty";
|
|
564
571
|
registerSchema({
|
|
565
572
|
command: "actions.create",
|
|
566
|
-
description: "Stage creation of a new action (applies when the chat is published). Returns a tempId you can use to link in the same draft. After creating, check if this action blocks or is blocked by other actions and wire dependencies with `baker actions link`.",
|
|
573
|
+
description: "Stage creation of a new action (applies when the chat is published). Returns a tempId you can use to link in the same draft. Tag the action with --tags (strongly encouraged \u2014 run `baker actions tags list` for the taxonomy). After creating, check if this action blocks or is blocked by other actions and wire dependencies with `baker actions link`.",
|
|
567
574
|
args: {
|
|
568
575
|
name: { type: "string", description: "Action name (short, action-verb, \u22646 words)", required: true },
|
|
569
576
|
description: {
|
|
@@ -571,6 +578,11 @@ registerSchema({
|
|
|
571
578
|
description: "Context-complete description: what / why / where / done-when",
|
|
572
579
|
required: false
|
|
573
580
|
},
|
|
581
|
+
tags: {
|
|
582
|
+
type: "string",
|
|
583
|
+
description: "Comma-separated tag slugs (e.g. google-ads,audit-finding). Must be known \u2014 see `baker actions tags list`.",
|
|
584
|
+
required: false
|
|
585
|
+
},
|
|
574
586
|
"temp-id": { type: "string", description: "Custom tempId (auto-generated if omitted)", required: false }
|
|
575
587
|
}
|
|
576
588
|
});
|
|
@@ -582,6 +594,7 @@ var createCommand = defineCommand3({
|
|
|
582
594
|
args: {
|
|
583
595
|
name: { type: "string", description: "Action name", required: false },
|
|
584
596
|
description: { type: "string", description: "Description", required: false, default: "" },
|
|
597
|
+
tags: { type: "string", description: "Comma-separated tag slugs (see `baker actions tags list`)", required: false },
|
|
585
598
|
"temp-id": { type: "string", description: "Optional custom tempId", required: false }
|
|
586
599
|
},
|
|
587
600
|
run: async ({ args }) => {
|
|
@@ -592,11 +605,13 @@ var createCommand = defineCommand3({
|
|
|
592
605
|
}
|
|
593
606
|
const chatId = requireChatId();
|
|
594
607
|
const tempId = args["temp-id"] || generateTempId();
|
|
608
|
+
const tags = parseTagList(args.tags);
|
|
595
609
|
const response = await apiPost("/api/actions/create", {
|
|
596
610
|
chatId,
|
|
597
611
|
tempId,
|
|
598
612
|
name,
|
|
599
|
-
description: args.description ?? ""
|
|
613
|
+
description: args.description ?? "",
|
|
614
|
+
...tags ? { tags } : {}
|
|
600
615
|
});
|
|
601
616
|
const hints = [];
|
|
602
617
|
if (looksScheduled(name, args.description ?? "")) {
|
|
@@ -608,6 +623,11 @@ var createCommand = defineCommand3({
|
|
|
608
623
|
if (!args.description) {
|
|
609
624
|
hints.push("Add description: baker actions update <tempId> --description '...' (what/why/where/done-when)");
|
|
610
625
|
}
|
|
626
|
+
if (!tags || tags.length === 0) {
|
|
627
|
+
hints.push(
|
|
628
|
+
"Tag this action so it's filterable in the backlog: re-run with --tags <slug,...> (run `baker actions tags list` for the taxonomy, or `baker actions update <tempId> --tags <slug,...>`)."
|
|
629
|
+
);
|
|
630
|
+
}
|
|
611
631
|
writeJson({ ...response, hints });
|
|
612
632
|
} catch (err) {
|
|
613
633
|
failApi(err);
|
|
@@ -853,7 +873,7 @@ var linkCommand = defineCommand7({
|
|
|
853
873
|
import { defineCommand as defineCommand8 } from "citty";
|
|
854
874
|
registerSchema({
|
|
855
875
|
command: "actions.list",
|
|
856
|
-
description: "List actions for the current company. Default: pre-bucketed (claimable/myClaims/blocked/claimedByOthers/completed/discarded). Set --bucketed=false for a flat list filterable by --status.",
|
|
876
|
+
description: "List actions for the current company. Default: pre-bucketed (claimable/myClaims/blocked/claimedByOthers/completed/discarded), each bucket ordered do-first (blockers before blocked, then highest-leverage). Set --bucketed=false for a flat list filterable by --status and orderable by --sort.",
|
|
857
877
|
args: {
|
|
858
878
|
bucketed: {
|
|
859
879
|
type: "boolean",
|
|
@@ -865,6 +885,11 @@ registerSchema({
|
|
|
865
885
|
type: "string",
|
|
866
886
|
description: "Filter by status (only with --bucketed=false): pending|in_progress|completed|discarded",
|
|
867
887
|
required: false
|
|
888
|
+
},
|
|
889
|
+
sort: {
|
|
890
|
+
type: "string",
|
|
891
|
+
description: "Order a flat list (only with --bucketed=false): priority (do-first: blockers before blocked, then highest-leverage) | recent. Default: priority.",
|
|
892
|
+
required: false
|
|
868
893
|
}
|
|
869
894
|
}
|
|
870
895
|
});
|
|
@@ -875,7 +900,8 @@ var listCommand2 = defineCommand8({
|
|
|
875
900
|
},
|
|
876
901
|
args: {
|
|
877
902
|
bucketed: { type: "boolean", description: "Pre-bucket by chat", required: false, default: true },
|
|
878
|
-
status: { type: "string", description: "Status filter (raw mode)", required: false }
|
|
903
|
+
status: { type: "string", description: "Status filter (raw mode)", required: false },
|
|
904
|
+
sort: { type: "string", description: "Order (raw mode): priority|recent", required: false }
|
|
879
905
|
},
|
|
880
906
|
run: async ({ args }) => {
|
|
881
907
|
try {
|
|
@@ -889,6 +915,7 @@ var listCommand2 = defineCommand8({
|
|
|
889
915
|
if (args.status) {
|
|
890
916
|
body.status = args.status;
|
|
891
917
|
}
|
|
918
|
+
body.sort = args.sort === "recent" ? "recent" : "priority";
|
|
892
919
|
}
|
|
893
920
|
const response = await apiPost("/api/actions/list", body);
|
|
894
921
|
writeJson(response);
|
|
@@ -965,8 +992,132 @@ var statusCommand = defineCommand10({
|
|
|
965
992
|
}
|
|
966
993
|
});
|
|
967
994
|
|
|
968
|
-
// src/commands/actions/
|
|
995
|
+
// src/commands/actions/tags/index.ts
|
|
996
|
+
import { defineCommand as defineCommand14 } from "citty";
|
|
997
|
+
|
|
998
|
+
// src/commands/actions/tags/create.ts
|
|
969
999
|
import { defineCommand as defineCommand11 } from "citty";
|
|
1000
|
+
registerSchema({
|
|
1001
|
+
command: "actions.tags.create",
|
|
1002
|
+
description: "Create a company custom action tag, minting a new slug usable with --tags. The name is slugified (lowercased, spaces\u2192hyphens). Use when no existing tag fits the work.",
|
|
1003
|
+
args: {
|
|
1004
|
+
slug: { type: "string", description: "Tag name/slug (e.g. pmax, retargeting)", required: true },
|
|
1005
|
+
description: { type: "string", description: "What this tag means", required: false }
|
|
1006
|
+
}
|
|
1007
|
+
});
|
|
1008
|
+
var tagsCreateCommand = defineCommand11({
|
|
1009
|
+
meta: {
|
|
1010
|
+
name: "create",
|
|
1011
|
+
description: 'Create a custom action tag. Example: baker actions tags create --slug pmax --description "Performance Max work"'
|
|
1012
|
+
},
|
|
1013
|
+
args: {
|
|
1014
|
+
slug: { type: "string", description: "Tag name/slug", required: false },
|
|
1015
|
+
description: { type: "string", description: "Description", required: false }
|
|
1016
|
+
},
|
|
1017
|
+
run: async ({ args }) => {
|
|
1018
|
+
try {
|
|
1019
|
+
const slug = args.slug;
|
|
1020
|
+
if (!slug || slug.trim().length === 0) {
|
|
1021
|
+
failValidation("--slug is required.");
|
|
1022
|
+
}
|
|
1023
|
+
const response = await apiPost("/api/actions/tags/create", {
|
|
1024
|
+
name: slug,
|
|
1025
|
+
description: args.description
|
|
1026
|
+
});
|
|
1027
|
+
writeOk(response.data);
|
|
1028
|
+
} catch (err) {
|
|
1029
|
+
failApi(err);
|
|
1030
|
+
}
|
|
1031
|
+
}
|
|
1032
|
+
});
|
|
1033
|
+
|
|
1034
|
+
// src/commands/actions/tags/delete.ts
|
|
1035
|
+
import { defineCommand as defineCommand12 } from "citty";
|
|
1036
|
+
registerSchema({
|
|
1037
|
+
command: "actions.tags.delete",
|
|
1038
|
+
description: "Delete a company custom action tag by slug. Built-in default tags cannot be deleted. Existing actions keep the slug (it just stops appearing in the taxonomy).",
|
|
1039
|
+
args: {
|
|
1040
|
+
slug: { type: "string", description: "Custom tag slug to delete", required: true }
|
|
1041
|
+
}
|
|
1042
|
+
});
|
|
1043
|
+
var tagsDeleteCommand = defineCommand12({
|
|
1044
|
+
meta: {
|
|
1045
|
+
name: "delete",
|
|
1046
|
+
description: "Delete a custom action tag. Example: baker actions tags delete --slug pmax"
|
|
1047
|
+
},
|
|
1048
|
+
args: {
|
|
1049
|
+
slug: { type: "string", description: "Custom tag slug", required: false }
|
|
1050
|
+
},
|
|
1051
|
+
run: async ({ args }) => {
|
|
1052
|
+
try {
|
|
1053
|
+
const slug = args.slug;
|
|
1054
|
+
if (!slug || slug.trim().length === 0) {
|
|
1055
|
+
failValidation("--slug is required.");
|
|
1056
|
+
}
|
|
1057
|
+
await apiPost("/api/actions/tags/delete", { name: slug });
|
|
1058
|
+
writeOk();
|
|
1059
|
+
} catch (err) {
|
|
1060
|
+
failApi(err);
|
|
1061
|
+
}
|
|
1062
|
+
}
|
|
1063
|
+
});
|
|
1064
|
+
|
|
1065
|
+
// src/commands/actions/tags/list.ts
|
|
1066
|
+
import { defineCommand as defineCommand13 } from "citty";
|
|
1067
|
+
registerSchema({
|
|
1068
|
+
command: "actions.tags.list",
|
|
1069
|
+
description: "List the available action tag taxonomy (built-in defaults + this company's custom tags). Tags are strict \u2014 only these names are accepted by --tags. Run before tagging.",
|
|
1070
|
+
args: { output: { type: "string", description: "Output format: md|json", required: false, default: "md" } }
|
|
1071
|
+
});
|
|
1072
|
+
var tagsListCommand = defineCommand13({
|
|
1073
|
+
meta: {
|
|
1074
|
+
name: "list",
|
|
1075
|
+
description: "List available action tag names (defaults + company custom tags). Use before --tags. Example: baker actions tags list"
|
|
1076
|
+
},
|
|
1077
|
+
args: { output: { type: "string", description: "Output format: md|json", required: false, default: "md" } },
|
|
1078
|
+
run: async ({ args }) => {
|
|
1079
|
+
try {
|
|
1080
|
+
const { markdown } = await apiGet("/api/actions/tags");
|
|
1081
|
+
if (args.output === "json") {
|
|
1082
|
+
writeJson({ ok: true, data: { markdown } });
|
|
1083
|
+
return;
|
|
1084
|
+
}
|
|
1085
|
+
process.stdout.write(`${markdown.trimEnd()}
|
|
1086
|
+
`);
|
|
1087
|
+
} catch (err) {
|
|
1088
|
+
const code = err instanceof ApiError ? err.code : "INTERNAL_ERROR";
|
|
1089
|
+
const message = err instanceof ApiError ? err.message : "Unexpected error";
|
|
1090
|
+
if (args.output === "json") {
|
|
1091
|
+
writeJson({ ok: false, error: { code, message } });
|
|
1092
|
+
} else {
|
|
1093
|
+
process.stderr.write(`Error: ${message}
|
|
1094
|
+
`);
|
|
1095
|
+
}
|
|
1096
|
+
process.exit(1);
|
|
1097
|
+
}
|
|
1098
|
+
}
|
|
1099
|
+
});
|
|
1100
|
+
|
|
1101
|
+
// src/commands/actions/tags/index.ts
|
|
1102
|
+
var tagsCommand = defineCommand14({
|
|
1103
|
+
meta: {
|
|
1104
|
+
name: "tags",
|
|
1105
|
+
description: `Manage the action tag taxonomy (built-in defaults + company custom tags). Tags are strict \u2014 only listed names work with --tags on create/update.
|
|
1106
|
+
|
|
1107
|
+
Examples:
|
|
1108
|
+
baker actions tags list # available tags (defaults + custom)
|
|
1109
|
+
baker actions tags create --slug pmax --description "\u2026" # mint a custom tag
|
|
1110
|
+
baker actions tags delete --slug pmax # remove a custom tag`
|
|
1111
|
+
},
|
|
1112
|
+
subCommands: {
|
|
1113
|
+
list: tagsListCommand,
|
|
1114
|
+
create: tagsCreateCommand,
|
|
1115
|
+
delete: tagsDeleteCommand
|
|
1116
|
+
}
|
|
1117
|
+
});
|
|
1118
|
+
|
|
1119
|
+
// src/commands/actions/unlink.ts
|
|
1120
|
+
import { defineCommand as defineCommand15 } from "citty";
|
|
970
1121
|
registerSchema({
|
|
971
1122
|
command: "actions.unlink",
|
|
972
1123
|
description: "Stage removal of a 'blocker -> blocked' dependency. The blocked action must be claimed by current chat.",
|
|
@@ -975,7 +1126,7 @@ registerSchema({
|
|
|
975
1126
|
blocked: { type: "string", description: "Blocked action ID (must be claimed by current chat)", required: true }
|
|
976
1127
|
}
|
|
977
1128
|
});
|
|
978
|
-
var unlinkCommand =
|
|
1129
|
+
var unlinkCommand = defineCommand15({
|
|
979
1130
|
meta: {
|
|
980
1131
|
name: "unlink",
|
|
981
1132
|
description: "Stage removal of a dependency. Example: baker actions unlink --blocker <id> --blocked <id>"
|
|
@@ -1007,17 +1158,22 @@ var unlinkCommand = defineCommand11({
|
|
|
1007
1158
|
});
|
|
1008
1159
|
|
|
1009
1160
|
// src/commands/actions/update.ts
|
|
1010
|
-
import { defineCommand as
|
|
1161
|
+
import { defineCommand as defineCommand16 } from "citty";
|
|
1011
1162
|
registerSchema({
|
|
1012
1163
|
command: "actions.update",
|
|
1013
|
-
description: "Stage an update on a claimed action (name and/or
|
|
1164
|
+
description: "Stage an update on a claimed action (name, description, and/or tags). Applies on publish. --tags REPLACES the tag set; pass --tags '' to clear all tags. Tags must be known \u2014 see `baker actions tags list`.",
|
|
1014
1165
|
args: {
|
|
1015
1166
|
id: { type: "string", description: "Action ID (must be claimed by current chat)", required: true },
|
|
1016
1167
|
name: { type: "string", description: "New name", required: false },
|
|
1017
|
-
description: { type: "string", description: "New description", required: false }
|
|
1168
|
+
description: { type: "string", description: "New description", required: false },
|
|
1169
|
+
tags: {
|
|
1170
|
+
type: "string",
|
|
1171
|
+
description: "Comma-separated tag slugs \u2014 REPLACES existing tags ('' clears)",
|
|
1172
|
+
required: false
|
|
1173
|
+
}
|
|
1018
1174
|
}
|
|
1019
1175
|
});
|
|
1020
|
-
var updateCommand =
|
|
1176
|
+
var updateCommand = defineCommand16({
|
|
1021
1177
|
meta: {
|
|
1022
1178
|
name: "update",
|
|
1023
1179
|
description: 'Stage an update on a claimed action. Example: baker actions update <id> --name "New name"'
|
|
@@ -1026,7 +1182,8 @@ var updateCommand = defineCommand12({
|
|
|
1026
1182
|
id: { type: "positional", description: "Action ID", required: false },
|
|
1027
1183
|
"action-id": { type: "string", description: "Action ID", required: false },
|
|
1028
1184
|
name: { type: "string", description: "New name", required: false },
|
|
1029
|
-
description: { type: "string", description: "New description", required: false }
|
|
1185
|
+
description: { type: "string", description: "New description", required: false },
|
|
1186
|
+
tags: { type: "string", description: "Comma-separated tag slugs \u2014 REPLACES existing ('' clears)", required: false }
|
|
1030
1187
|
},
|
|
1031
1188
|
run: async ({ args }) => {
|
|
1032
1189
|
try {
|
|
@@ -1035,15 +1192,17 @@ var updateCommand = defineCommand12({
|
|
|
1035
1192
|
failValidation("Action ID is required.");
|
|
1036
1193
|
}
|
|
1037
1194
|
validateConvexId(id);
|
|
1038
|
-
|
|
1039
|
-
|
|
1195
|
+
const tags = parseTagList(args.tags);
|
|
1196
|
+
if (args.name === void 0 && args.description === void 0 && tags === void 0) {
|
|
1197
|
+
failValidation("Provide at least one of --name, --description, --tags.");
|
|
1040
1198
|
}
|
|
1041
1199
|
const chatId = requireChatId();
|
|
1042
1200
|
await apiPost("/api/actions/update", {
|
|
1043
1201
|
chatId,
|
|
1044
1202
|
actionId: id,
|
|
1045
1203
|
name: args.name,
|
|
1046
|
-
description: args.description
|
|
1204
|
+
description: args.description,
|
|
1205
|
+
...tags !== void 0 ? { tags } : {}
|
|
1047
1206
|
});
|
|
1048
1207
|
writeOk();
|
|
1049
1208
|
} catch (err) {
|
|
@@ -1053,7 +1212,7 @@ var updateCommand = defineCommand12({
|
|
|
1053
1212
|
});
|
|
1054
1213
|
|
|
1055
1214
|
// src/commands/actions/index.ts
|
|
1056
|
-
var actionsCommand =
|
|
1215
|
+
var actionsCommand = defineCommand17({
|
|
1057
1216
|
meta: {
|
|
1058
1217
|
name: "actions",
|
|
1059
1218
|
description: `Manage action items for the current chat. Subcommands: list, draft, get, status, claim, release, create, update, complete, discard, link, unlink.
|
|
@@ -1068,8 +1227,9 @@ Examples:
|
|
|
1068
1227
|
baker actions draft remove temp_hero # drop a staged create (cascades its complete/link ops)
|
|
1069
1228
|
baker actions draft clear # drop everything staged in this chat
|
|
1070
1229
|
baker actions status temp_hero jx123 # batch resolve real IDs and temp_* refs
|
|
1230
|
+
baker actions tags list # available tags (defaults + company custom)
|
|
1071
1231
|
baker actions claim <id>
|
|
1072
|
-
baker actions create --name "Build hero" --description "..."
|
|
1232
|
+
baker actions create --name "Build hero" --tags landing,creative --description "..."
|
|
1073
1233
|
baker actions complete <id>
|
|
1074
1234
|
baker actions discard <id> --reason "obsolete"`
|
|
1075
1235
|
},
|
|
@@ -1085,18 +1245,19 @@ Examples:
|
|
|
1085
1245
|
complete: completeCommand,
|
|
1086
1246
|
discard: discardCommand,
|
|
1087
1247
|
link: linkCommand,
|
|
1088
|
-
unlink: unlinkCommand
|
|
1248
|
+
unlink: unlinkCommand,
|
|
1249
|
+
tags: tagsCommand
|
|
1089
1250
|
}
|
|
1090
1251
|
});
|
|
1091
1252
|
|
|
1092
1253
|
// src/commands/ads/index.ts
|
|
1093
|
-
import { defineCommand as
|
|
1254
|
+
import { defineCommand as defineCommand77 } from "citty";
|
|
1094
1255
|
|
|
1095
1256
|
// src/commands/ads/google/index.ts
|
|
1096
|
-
import { defineCommand as
|
|
1257
|
+
import { defineCommand as defineCommand28 } from "citty";
|
|
1097
1258
|
|
|
1098
1259
|
// src/commands/ads/google/accounts.ts
|
|
1099
|
-
import { defineCommand as
|
|
1260
|
+
import { defineCommand as defineCommand18 } from "citty";
|
|
1100
1261
|
|
|
1101
1262
|
// src/commands/ads/cache.ts
|
|
1102
1263
|
import { createHash } from "crypto";
|
|
@@ -1372,7 +1533,7 @@ function handleAccountsError(err) {
|
|
|
1372
1533
|
writeAdsJson({ ok: false, error: { code: "NETWORK_ERROR", message: "Unexpected error" } });
|
|
1373
1534
|
process.exit(1);
|
|
1374
1535
|
}
|
|
1375
|
-
var accountsCommand =
|
|
1536
|
+
var accountsCommand = defineCommand18({
|
|
1376
1537
|
meta: {
|
|
1377
1538
|
name: "accounts",
|
|
1378
1539
|
description: `List accessible Google Ads accounts. Returns customer IDs needed for all other commands.
|
|
@@ -1412,7 +1573,7 @@ Examples:
|
|
|
1412
1573
|
});
|
|
1413
1574
|
|
|
1414
1575
|
// src/commands/ads/google/changes.ts
|
|
1415
|
-
import { defineCommand as
|
|
1576
|
+
import { defineCommand as defineCommand19 } from "citty";
|
|
1416
1577
|
|
|
1417
1578
|
// src/commands/ads/field-descriptions.ts
|
|
1418
1579
|
var FIELD_DESCRIPTIONS = {
|
|
@@ -1964,7 +2125,7 @@ registerSchema({
|
|
|
1964
2125
|
output: { type: "string", description: "Format: json|csv|jsonl|md", required: false, default: "json" }
|
|
1965
2126
|
}
|
|
1966
2127
|
});
|
|
1967
|
-
var changesCommand =
|
|
2128
|
+
var changesCommand = defineCommand19({
|
|
1968
2129
|
meta: {
|
|
1969
2130
|
name: "changes",
|
|
1970
2131
|
description: `Get recent changes in a Google Ads account with performance data.
|
|
@@ -2015,7 +2176,7 @@ Examples:
|
|
|
2015
2176
|
});
|
|
2016
2177
|
|
|
2017
2178
|
// src/commands/ads/google/currency.ts
|
|
2018
|
-
import { defineCommand as
|
|
2179
|
+
import { defineCommand as defineCommand20 } from "citty";
|
|
2019
2180
|
registerSchema({
|
|
2020
2181
|
command: "ads.google.currency",
|
|
2021
2182
|
description: "Get the currency code for a Google Ads account. Returns currency_code, customer_id, account_name, and access_type. Call this before interpreting cost_micros values.",
|
|
@@ -2027,7 +2188,7 @@ registerSchema({
|
|
|
2027
2188
|
}
|
|
2028
2189
|
}
|
|
2029
2190
|
});
|
|
2030
|
-
var currencyCommand =
|
|
2191
|
+
var currencyCommand = defineCommand20({
|
|
2031
2192
|
meta: {
|
|
2032
2193
|
name: "currency",
|
|
2033
2194
|
description: `Get account currency code. Use this to interpret metrics.cost_micros values.
|
|
@@ -2076,10 +2237,10 @@ Examples:
|
|
|
2076
2237
|
});
|
|
2077
2238
|
|
|
2078
2239
|
// src/commands/ads/google/keywords/index.ts
|
|
2079
|
-
import { defineCommand as
|
|
2240
|
+
import { defineCommand as defineCommand25 } from "citty";
|
|
2080
2241
|
|
|
2081
2242
|
// src/commands/ads/google/keywords/discover.ts
|
|
2082
|
-
import { defineCommand as
|
|
2243
|
+
import { defineCommand as defineCommand21 } from "citty";
|
|
2083
2244
|
|
|
2084
2245
|
// src/geo-context.ts
|
|
2085
2246
|
var GOOGLE_ADS_LOCATIONS = [
|
|
@@ -2354,7 +2515,7 @@ function handleKeywordError(err) {
|
|
|
2354
2515
|
writeAdsJson({ ok: false, error: { code: "NETWORK_ERROR", message: "Unexpected error" } });
|
|
2355
2516
|
process.exit(1);
|
|
2356
2517
|
}
|
|
2357
|
-
var discoverCommand =
|
|
2518
|
+
var discoverCommand = defineCommand21({
|
|
2358
2519
|
meta: {
|
|
2359
2520
|
name: "discover",
|
|
2360
2521
|
description: `Discover new keyword ideas from seed keywords or competitor URLs.
|
|
@@ -2416,7 +2577,7 @@ Examples:
|
|
|
2416
2577
|
});
|
|
2417
2578
|
|
|
2418
2579
|
// src/commands/ads/google/keywords/languages.ts
|
|
2419
|
-
import { defineCommand as
|
|
2580
|
+
import { defineCommand as defineCommand22 } from "citty";
|
|
2420
2581
|
registerSchema({
|
|
2421
2582
|
command: "ads.google.keywords.languages",
|
|
2422
2583
|
description: "List all supported language IDs for --language flag in Google Ads keyword commands.",
|
|
@@ -2426,7 +2587,7 @@ var FIELDS = {
|
|
|
2426
2587
|
id: "Language ID to pass as --language",
|
|
2427
2588
|
name: "Language name"
|
|
2428
2589
|
};
|
|
2429
|
-
var languagesCommand =
|
|
2590
|
+
var languagesCommand = defineCommand22({
|
|
2430
2591
|
meta: {
|
|
2431
2592
|
name: "languages",
|
|
2432
2593
|
description: "List all supported language IDs for --language flag."
|
|
@@ -2437,7 +2598,7 @@ var languagesCommand = defineCommand18({
|
|
|
2437
2598
|
});
|
|
2438
2599
|
|
|
2439
2600
|
// src/commands/ads/google/keywords/locations.ts
|
|
2440
|
-
import { defineCommand as
|
|
2601
|
+
import { defineCommand as defineCommand23 } from "citty";
|
|
2441
2602
|
registerSchema({
|
|
2442
2603
|
command: "ads.google.keywords.locations",
|
|
2443
2604
|
description: "List all supported geo target IDs for --location flag in Google Ads keyword commands.",
|
|
@@ -2447,7 +2608,7 @@ var FIELDS2 = {
|
|
|
2447
2608
|
id: "Geo target ID to pass as --location",
|
|
2448
2609
|
name: "Country/region name"
|
|
2449
2610
|
};
|
|
2450
|
-
var locationsCommand =
|
|
2611
|
+
var locationsCommand = defineCommand23({
|
|
2451
2612
|
meta: {
|
|
2452
2613
|
name: "locations",
|
|
2453
2614
|
description: "List all supported geo target IDs for --location flag."
|
|
@@ -2458,7 +2619,7 @@ var locationsCommand = defineCommand19({
|
|
|
2458
2619
|
});
|
|
2459
2620
|
|
|
2460
2621
|
// src/commands/ads/google/keywords/metrics.ts
|
|
2461
|
-
import { defineCommand as
|
|
2622
|
+
import { defineCommand as defineCommand24 } from "citty";
|
|
2462
2623
|
registerSchema({
|
|
2463
2624
|
command: "ads.google.keywords.metrics",
|
|
2464
2625
|
description: "Get historical metrics for specific keywords. Returns { historical_metrics: [...] } with snake_case fields matching the Google Ads API. IMPORTANT: If --location and --language are omitted, defaults to United States (2840) and English (1000). The response includes a query_context object showing which location/language were used.",
|
|
@@ -2482,7 +2643,7 @@ registerSchema({
|
|
|
2482
2643
|
output: { type: "string", description: "Format: json|csv|jsonl|md", required: false, default: "json" }
|
|
2483
2644
|
}
|
|
2484
2645
|
});
|
|
2485
|
-
var metricsCommand =
|
|
2646
|
+
var metricsCommand = defineCommand24({
|
|
2486
2647
|
meta: {
|
|
2487
2648
|
name: "metrics",
|
|
2488
2649
|
description: `Get historical search metrics for specific keywords.
|
|
@@ -2569,7 +2730,7 @@ Examples:
|
|
|
2569
2730
|
});
|
|
2570
2731
|
|
|
2571
2732
|
// src/commands/ads/google/keywords/index.ts
|
|
2572
|
-
var keywordsCommand =
|
|
2733
|
+
var keywordsCommand = defineCommand25({
|
|
2573
2734
|
meta: {
|
|
2574
2735
|
name: "keywords",
|
|
2575
2736
|
description: `Keyword research tools. Subcommands: discover, metrics, locations, languages.
|
|
@@ -2589,8 +2750,8 @@ Examples:
|
|
|
2589
2750
|
});
|
|
2590
2751
|
|
|
2591
2752
|
// src/commands/ads/google/library/index.ts
|
|
2592
|
-
import { defineCommand as
|
|
2593
|
-
var listAdvertisers =
|
|
2753
|
+
import { defineCommand as defineCommand26 } from "citty";
|
|
2754
|
+
var listAdvertisers = defineCommand26({
|
|
2594
2755
|
meta: {
|
|
2595
2756
|
name: "list-advertisers",
|
|
2596
2757
|
description: "List tracked Google advertisers and their accounts"
|
|
@@ -2607,7 +2768,7 @@ var listAdvertisers = defineCommand22({
|
|
|
2607
2768
|
}
|
|
2608
2769
|
}
|
|
2609
2770
|
});
|
|
2610
|
-
var syncStatus =
|
|
2771
|
+
var syncStatus = defineCommand26({
|
|
2611
2772
|
meta: {
|
|
2612
2773
|
name: "sync-status",
|
|
2613
2774
|
description: "Check the sync status and ad counts of a Google account"
|
|
@@ -2627,7 +2788,7 @@ var syncStatus = defineCommand22({
|
|
|
2627
2788
|
writeAdsJson({ ok: true, data });
|
|
2628
2789
|
}
|
|
2629
2790
|
});
|
|
2630
|
-
var searchAds =
|
|
2791
|
+
var searchAds = defineCommand26({
|
|
2631
2792
|
meta: {
|
|
2632
2793
|
name: "search-ads",
|
|
2633
2794
|
description: "Search and filter Google ads for an account"
|
|
@@ -2684,7 +2845,7 @@ var searchAds = defineCommand22({
|
|
|
2684
2845
|
}
|
|
2685
2846
|
}
|
|
2686
2847
|
});
|
|
2687
|
-
var searchAdvertiser =
|
|
2848
|
+
var searchAdvertiser = defineCommand26({
|
|
2688
2849
|
meta: {
|
|
2689
2850
|
name: "search-advertiser",
|
|
2690
2851
|
description: "Search for an advertiser on the Google Ads Transparency Center"
|
|
@@ -2719,7 +2880,7 @@ var searchAdvertiser = defineCommand22({
|
|
|
2719
2880
|
function sleep(ms) {
|
|
2720
2881
|
return new Promise((resolve5) => setTimeout(resolve5, ms));
|
|
2721
2882
|
}
|
|
2722
|
-
var track =
|
|
2883
|
+
var track = defineCommand26({
|
|
2723
2884
|
meta: {
|
|
2724
2885
|
name: "track",
|
|
2725
2886
|
description: "Track a new Google advertiser (from search results). Waits for initial sync to complete before returning."
|
|
@@ -2777,7 +2938,7 @@ var track = defineCommand22({
|
|
|
2777
2938
|
process.exit(1);
|
|
2778
2939
|
}
|
|
2779
2940
|
});
|
|
2780
|
-
var sync =
|
|
2941
|
+
var sync = defineCommand26({
|
|
2781
2942
|
meta: {
|
|
2782
2943
|
name: "sync",
|
|
2783
2944
|
description: "Trigger an immediate sync for a Google account. Waits for completion before returning."
|
|
@@ -2821,7 +2982,7 @@ var sync = defineCommand22({
|
|
|
2821
2982
|
process.exit(1);
|
|
2822
2983
|
}
|
|
2823
2984
|
});
|
|
2824
|
-
var searchCompetitors =
|
|
2985
|
+
var searchCompetitors = defineCommand26({
|
|
2825
2986
|
meta: {
|
|
2826
2987
|
name: "search-competitors",
|
|
2827
2988
|
description: "Search for competitors running Google ads for a keyword (DataForSEO)"
|
|
@@ -2853,7 +3014,7 @@ var searchCompetitors = defineCommand22({
|
|
|
2853
3014
|
}
|
|
2854
3015
|
}
|
|
2855
3016
|
});
|
|
2856
|
-
var library =
|
|
3017
|
+
var library = defineCommand26({
|
|
2857
3018
|
meta: {
|
|
2858
3019
|
name: "library",
|
|
2859
3020
|
description: "Manage and search the Google Ads Library"
|
|
@@ -2872,7 +3033,7 @@ var library = defineCommand22({
|
|
|
2872
3033
|
// src/commands/ads/google/query.ts
|
|
2873
3034
|
import { appendFileSync, existsSync as existsSync2, readFileSync as readFileSync2, writeFileSync as writeFileSync2 } from "fs";
|
|
2874
3035
|
import { resolve } from "path";
|
|
2875
|
-
import { defineCommand as
|
|
3036
|
+
import { defineCommand as defineCommand27 } from "citty";
|
|
2876
3037
|
|
|
2877
3038
|
// src/commands/ads/google/preflight.ts
|
|
2878
3039
|
function buildCommand2(query, customerId) {
|
|
@@ -3328,7 +3489,7 @@ function handleQueryError(err, finalQuery, customerId) {
|
|
|
3328
3489
|
});
|
|
3329
3490
|
process.exit(1);
|
|
3330
3491
|
}
|
|
3331
|
-
var queryCommand =
|
|
3492
|
+
var queryCommand = defineCommand27({
|
|
3332
3493
|
meta: {
|
|
3333
3494
|
name: "query",
|
|
3334
3495
|
description: `Run GAQL queries against Google Ads. Supports raw GAQL, presets, pagination, file export, and caching.
|
|
@@ -3386,7 +3547,7 @@ Examples:
|
|
|
3386
3547
|
});
|
|
3387
3548
|
|
|
3388
3549
|
// src/commands/ads/google/index.ts
|
|
3389
|
-
var googleCommand =
|
|
3550
|
+
var googleCommand = defineCommand28({
|
|
3390
3551
|
meta: {
|
|
3391
3552
|
name: "google",
|
|
3392
3553
|
description: `Google Ads commands. Query campaigns, keywords, search terms, and more via GAQL.
|
|
@@ -3414,7 +3575,7 @@ Examples:
|
|
|
3414
3575
|
});
|
|
3415
3576
|
|
|
3416
3577
|
// src/commands/ads/linkedin/index.ts
|
|
3417
|
-
import { defineCommand as
|
|
3578
|
+
import { defineCommand as defineCommand46 } from "citty";
|
|
3418
3579
|
|
|
3419
3580
|
// src/commands/ads/linkedin/schemas.ts
|
|
3420
3581
|
registerSchema({
|
|
@@ -3714,7 +3875,7 @@ registerSchema({
|
|
|
3714
3875
|
});
|
|
3715
3876
|
|
|
3716
3877
|
// src/commands/ads/linkedin/account.ts
|
|
3717
|
-
import { defineCommand as
|
|
3878
|
+
import { defineCommand as defineCommand29 } from "citty";
|
|
3718
3879
|
|
|
3719
3880
|
// src/commands/ads/linkedin/shared.ts
|
|
3720
3881
|
var DAY_MS = 864e5;
|
|
@@ -3817,7 +3978,7 @@ function resolveStatusFilter(args) {
|
|
|
3817
3978
|
}
|
|
3818
3979
|
|
|
3819
3980
|
// src/commands/ads/linkedin/account.ts
|
|
3820
|
-
var accountCommand =
|
|
3981
|
+
var accountCommand = defineCommand29({
|
|
3821
3982
|
meta: {
|
|
3822
3983
|
name: "account",
|
|
3823
3984
|
description: `Single LinkedIn ad account detail (currency, status, type).
|
|
@@ -3851,9 +4012,9 @@ Examples:
|
|
|
3851
4012
|
});
|
|
3852
4013
|
|
|
3853
4014
|
// src/commands/ads/linkedin/accounts.ts
|
|
3854
|
-
import { defineCommand as
|
|
4015
|
+
import { defineCommand as defineCommand30 } from "citty";
|
|
3855
4016
|
var ACCOUNTS_TTL_MS = 60 * 60 * 1e3;
|
|
3856
|
-
var accountsCommand2 =
|
|
4017
|
+
var accountsCommand2 = defineCommand30({
|
|
3857
4018
|
meta: {
|
|
3858
4019
|
name: "accounts",
|
|
3859
4020
|
description: `List LinkedIn ad accounts in this company's connected scope.
|
|
@@ -3901,7 +4062,7 @@ Examples:
|
|
|
3901
4062
|
});
|
|
3902
4063
|
|
|
3903
4064
|
// src/commands/ads/linkedin/analytics.ts
|
|
3904
|
-
import { defineCommand as
|
|
4065
|
+
import { defineCommand as defineCommand31 } from "citty";
|
|
3905
4066
|
|
|
3906
4067
|
// src/commands/ads/linkedin/presets.ts
|
|
3907
4068
|
var INTENTS = {
|
|
@@ -4173,7 +4334,7 @@ function numberOf(v) {
|
|
|
4173
4334
|
}
|
|
4174
4335
|
return 0;
|
|
4175
4336
|
}
|
|
4176
|
-
var analyticsCommand =
|
|
4337
|
+
var analyticsCommand = defineCommand31({
|
|
4177
4338
|
meta: {
|
|
4178
4339
|
name: "analytics",
|
|
4179
4340
|
description: `Performance reporting \u2014 the workhorse for AI agents.
|
|
@@ -4301,7 +4462,7 @@ Examples \u2014 common AI questions:
|
|
|
4301
4462
|
|
|
4302
4463
|
// src/commands/ads/linkedin/audience-size.ts
|
|
4303
4464
|
import { readFileSync as readFileSync3 } from "fs";
|
|
4304
|
-
import { defineCommand as
|
|
4465
|
+
import { defineCommand as defineCommand32 } from "citty";
|
|
4305
4466
|
function loadTargeting(args) {
|
|
4306
4467
|
const inline = args.targeting;
|
|
4307
4468
|
if (inline) {
|
|
@@ -4323,7 +4484,7 @@ function loadTargeting(args) {
|
|
|
4323
4484
|
}
|
|
4324
4485
|
handleLinkedinError(new Error("Pass --targeting-file <path> or --targeting '{...JSON...}'"));
|
|
4325
4486
|
}
|
|
4326
|
-
var audienceSizeCommand =
|
|
4487
|
+
var audienceSizeCommand = defineCommand32({
|
|
4327
4488
|
meta: {
|
|
4328
4489
|
name: "audience-size",
|
|
4329
4490
|
description: `Estimate audience size for a targeting payload \u2014 pre-launch sanity check.
|
|
@@ -4368,7 +4529,7 @@ Examples:
|
|
|
4368
4529
|
});
|
|
4369
4530
|
|
|
4370
4531
|
// src/commands/ads/linkedin/audit.ts
|
|
4371
|
-
import { defineCommand as
|
|
4532
|
+
import { defineCommand as defineCommand33 } from "citty";
|
|
4372
4533
|
var SEVERITY_RANK = {
|
|
4373
4534
|
critical: 0,
|
|
4374
4535
|
high: 1,
|
|
@@ -4427,7 +4588,7 @@ function noteOf(f) {
|
|
|
4427
4588
|
const fix = f.fix?.explanation ?? "";
|
|
4428
4589
|
return [fix, ev].filter(Boolean).join(" \u2014 ");
|
|
4429
4590
|
}
|
|
4430
|
-
var auditCommand =
|
|
4591
|
+
var auditCommand = defineCommand33({
|
|
4431
4592
|
meta: {
|
|
4432
4593
|
name: "audit",
|
|
4433
4594
|
description: `Run a LinkedIn Ads playbook audit \u2014 30+ checks across Settings, Tracking,
|
|
@@ -4494,7 +4655,7 @@ Examples:
|
|
|
4494
4655
|
|
|
4495
4656
|
// src/commands/ads/linkedin/bid-pricing.ts
|
|
4496
4657
|
import { readFileSync as readFileSync4 } from "fs";
|
|
4497
|
-
import { defineCommand as
|
|
4658
|
+
import { defineCommand as defineCommand34 } from "citty";
|
|
4498
4659
|
function loadTargeting2(args) {
|
|
4499
4660
|
const inline = args.targeting;
|
|
4500
4661
|
if (inline) {
|
|
@@ -4516,7 +4677,7 @@ function loadTargeting2(args) {
|
|
|
4516
4677
|
}
|
|
4517
4678
|
handleLinkedinError(new Error("Pass --targeting-file <path> or --targeting '{...JSON...}'"));
|
|
4518
4679
|
}
|
|
4519
|
-
var bidPricingCommand =
|
|
4680
|
+
var bidPricingCommand = defineCommand34({
|
|
4520
4681
|
meta: {
|
|
4521
4682
|
name: "bid-pricing",
|
|
4522
4683
|
description: `Get LinkedIn's suggested bid range for a targeting + objective + cost type.
|
|
@@ -4566,8 +4727,8 @@ Examples:
|
|
|
4566
4727
|
});
|
|
4567
4728
|
|
|
4568
4729
|
// src/commands/ads/linkedin/campaign-groups.ts
|
|
4569
|
-
import { defineCommand as
|
|
4570
|
-
var campaignGroupsCommand =
|
|
4730
|
+
import { defineCommand as defineCommand35 } from "citty";
|
|
4731
|
+
var campaignGroupsCommand = defineCommand35({
|
|
4571
4732
|
meta: {
|
|
4572
4733
|
name: "campaign-groups",
|
|
4573
4734
|
description: `List LinkedIn campaign groups.
|
|
@@ -4610,8 +4771,8 @@ Examples:
|
|
|
4610
4771
|
});
|
|
4611
4772
|
|
|
4612
4773
|
// src/commands/ads/linkedin/campaigns.ts
|
|
4613
|
-
import { defineCommand as
|
|
4614
|
-
var campaignsCommand =
|
|
4774
|
+
import { defineCommand as defineCommand36 } from "citty";
|
|
4775
|
+
var campaignsCommand = defineCommand36({
|
|
4615
4776
|
meta: {
|
|
4616
4777
|
name: "campaigns",
|
|
4617
4778
|
description: `List LinkedIn campaigns.
|
|
@@ -4660,8 +4821,8 @@ Examples:
|
|
|
4660
4821
|
});
|
|
4661
4822
|
|
|
4662
4823
|
// src/commands/ads/linkedin/conversation.ts
|
|
4663
|
-
import { defineCommand as
|
|
4664
|
-
var conversationCommand =
|
|
4824
|
+
import { defineCommand as defineCommand37 } from "citty";
|
|
4825
|
+
var conversationCommand = defineCommand37({
|
|
4665
4826
|
meta: {
|
|
4666
4827
|
name: "conversation",
|
|
4667
4828
|
description: `Per-button click rates inside Sponsored Messaging / Conversation Ads.
|
|
@@ -4724,7 +4885,7 @@ Examples:
|
|
|
4724
4885
|
});
|
|
4725
4886
|
|
|
4726
4887
|
// src/commands/ads/linkedin/conversions.ts
|
|
4727
|
-
import { defineCommand as
|
|
4888
|
+
import { defineCommand as defineCommand38 } from "citty";
|
|
4728
4889
|
var DAY_MS2 = 864e5;
|
|
4729
4890
|
function healthOf(rules) {
|
|
4730
4891
|
const enabled = rules.filter((r) => r.enabled !== false);
|
|
@@ -4750,7 +4911,7 @@ function healthOf(rules) {
|
|
|
4750
4911
|
wrongLeadDedup: wrongDedup
|
|
4751
4912
|
};
|
|
4752
4913
|
}
|
|
4753
|
-
var listCmd =
|
|
4914
|
+
var listCmd = defineCommand38({
|
|
4754
4915
|
meta: {
|
|
4755
4916
|
name: "list",
|
|
4756
4917
|
description: `List conversion rules on the account.`
|
|
@@ -4778,7 +4939,7 @@ var listCmd = defineCommand34({
|
|
|
4778
4939
|
}
|
|
4779
4940
|
}
|
|
4780
4941
|
});
|
|
4781
|
-
var healthCmd =
|
|
4942
|
+
var healthCmd = defineCommand38({
|
|
4782
4943
|
meta: {
|
|
4783
4944
|
name: "health",
|
|
4784
4945
|
description: `5-point Insight Tag / CAPI health check (playbook \xA707).
|
|
@@ -4808,7 +4969,7 @@ Surfaces:
|
|
|
4808
4969
|
}
|
|
4809
4970
|
}
|
|
4810
4971
|
});
|
|
4811
|
-
var conversionsCommand =
|
|
4972
|
+
var conversionsCommand = defineCommand38({
|
|
4812
4973
|
meta: {
|
|
4813
4974
|
name: "conversions",
|
|
4814
4975
|
description: `Conversion rules \u2014 Insight Tag and Conversions API.
|
|
@@ -4824,8 +4985,8 @@ Subcommands:
|
|
|
4824
4985
|
});
|
|
4825
4986
|
|
|
4826
4987
|
// src/commands/ads/linkedin/creatives.ts
|
|
4827
|
-
import { defineCommand as
|
|
4828
|
-
var creativesCommand =
|
|
4988
|
+
import { defineCommand as defineCommand39 } from "citty";
|
|
4989
|
+
var creativesCommand = defineCommand39({
|
|
4829
4990
|
meta: {
|
|
4830
4991
|
name: "creatives",
|
|
4831
4992
|
description: `List LinkedIn creatives (ads).
|
|
@@ -4874,7 +5035,7 @@ Examples:
|
|
|
4874
5035
|
});
|
|
4875
5036
|
|
|
4876
5037
|
// src/commands/ads/linkedin/demographics.ts
|
|
4877
|
-
import { defineCommand as
|
|
5038
|
+
import { defineCommand as defineCommand40 } from "citty";
|
|
4878
5039
|
var DEFAULT_PIVOTS = ["job-title", "company", "industry", "seniority", "job-function", "company-size"];
|
|
4879
5040
|
function numberOf2(v) {
|
|
4880
5041
|
if (typeof v === "number") return Number.isFinite(v) ? v : 0;
|
|
@@ -4887,7 +5048,7 @@ function numberOf2(v) {
|
|
|
4887
5048
|
function topByImpressions(rows, limit) {
|
|
4888
5049
|
return [...rows].sort((a, b) => numberOf2(b.impressions) - numberOf2(a.impressions)).slice(0, limit);
|
|
4889
5050
|
}
|
|
4890
|
-
var demographicsCommand =
|
|
5051
|
+
var demographicsCommand = defineCommand40({
|
|
4891
5052
|
meta: {
|
|
4892
5053
|
name: "demographics",
|
|
4893
5054
|
description: `Sweep all firmographic pivots in one command \u2014 LinkedIn's superpower.
|
|
@@ -4984,8 +5145,8 @@ function resolveRange(args) {
|
|
|
4984
5145
|
}
|
|
4985
5146
|
|
|
4986
5147
|
// src/commands/ads/linkedin/facets.ts
|
|
4987
|
-
import { defineCommand as
|
|
4988
|
-
var listCmd2 =
|
|
5148
|
+
import { defineCommand as defineCommand41 } from "citty";
|
|
5149
|
+
var listCmd2 = defineCommand41({
|
|
4989
5150
|
meta: {
|
|
4990
5151
|
name: "list",
|
|
4991
5152
|
description: `List every targeting facet LinkedIn supports.
|
|
@@ -5013,7 +5174,7 @@ seniorities, titles, employers, growthRate, companyCategory, skills, etc.).`
|
|
|
5013
5174
|
}
|
|
5014
5175
|
}
|
|
5015
5176
|
});
|
|
5016
|
-
var valuesCmd =
|
|
5177
|
+
var valuesCmd = defineCommand41({
|
|
5017
5178
|
meta: {
|
|
5018
5179
|
name: "values",
|
|
5019
5180
|
description: `Look up entity values for a single facet \u2014 full list or typeahead search.
|
|
@@ -5054,7 +5215,7 @@ or the full URN (urn:li:adTargetingFacet:industries).`
|
|
|
5054
5215
|
}
|
|
5055
5216
|
}
|
|
5056
5217
|
});
|
|
5057
|
-
var facetsCommand =
|
|
5218
|
+
var facetsCommand = defineCommand41({
|
|
5058
5219
|
meta: {
|
|
5059
5220
|
name: "facets",
|
|
5060
5221
|
description: `LinkedIn targeting facets and entity lookup.
|
|
@@ -5072,7 +5233,7 @@ Subcommands:
|
|
|
5072
5233
|
|
|
5073
5234
|
// src/commands/ads/linkedin/forecast.ts
|
|
5074
5235
|
import { readFileSync as readFileSync5 } from "fs";
|
|
5075
|
-
import { defineCommand as
|
|
5236
|
+
import { defineCommand as defineCommand42 } from "citty";
|
|
5076
5237
|
function loadTargeting3(args) {
|
|
5077
5238
|
const inline = args.targeting;
|
|
5078
5239
|
if (inline) {
|
|
@@ -5102,7 +5263,7 @@ function parseMoney(raw) {
|
|
|
5102
5263
|
}
|
|
5103
5264
|
return { amount: m[1] ?? "0", currencyCode: m[2] ?? "USD" };
|
|
5104
5265
|
}
|
|
5105
|
-
var forecastCommand =
|
|
5266
|
+
var forecastCommand = defineCommand42({
|
|
5106
5267
|
meta: {
|
|
5107
5268
|
name: "forecast",
|
|
5108
5269
|
description: `Forecast reach + impressions + clicks + spend for a hypothetical campaign.
|
|
@@ -5149,9 +5310,9 @@ Examples:
|
|
|
5149
5310
|
});
|
|
5150
5311
|
|
|
5151
5312
|
// src/commands/ads/linkedin/leads.ts
|
|
5152
|
-
import { defineCommand as
|
|
5313
|
+
import { defineCommand as defineCommand43 } from "citty";
|
|
5153
5314
|
var DAY_MS3 = 864e5;
|
|
5154
|
-
var leadsCommand =
|
|
5315
|
+
var leadsCommand = defineCommand43({
|
|
5155
5316
|
meta: {
|
|
5156
5317
|
name: "leads",
|
|
5157
5318
|
description: `List Lead Gen Form responses (playbook \xA707).
|
|
@@ -5211,7 +5372,7 @@ Examples:
|
|
|
5211
5372
|
});
|
|
5212
5373
|
|
|
5213
5374
|
// src/commands/ads/linkedin/resolve.ts
|
|
5214
|
-
import { defineCommand as
|
|
5375
|
+
import { defineCommand as defineCommand44 } from "citty";
|
|
5215
5376
|
function toOrgUrn(raw) {
|
|
5216
5377
|
const trimmed = raw.trim();
|
|
5217
5378
|
if (trimmed.length === 0) {
|
|
@@ -5222,7 +5383,7 @@ function toOrgUrn(raw) {
|
|
|
5222
5383
|
}
|
|
5223
5384
|
return /^\d+$/.test(trimmed) ? `urn:li:organization:${trimmed}` : null;
|
|
5224
5385
|
}
|
|
5225
|
-
var resolveCommand =
|
|
5386
|
+
var resolveCommand = defineCommand44({
|
|
5226
5387
|
meta: {
|
|
5227
5388
|
name: "resolve",
|
|
5228
5389
|
description: `Resolve organization URNs to company names.
|
|
@@ -5264,8 +5425,8 @@ couldn't be resolved \u2014 typically an org outside LinkedIn's targetable set.`
|
|
|
5264
5425
|
});
|
|
5265
5426
|
|
|
5266
5427
|
// src/commands/ads/linkedin/top-companies.ts
|
|
5267
|
-
import { defineCommand as
|
|
5268
|
-
var topCompaniesCommand =
|
|
5428
|
+
import { defineCommand as defineCommand45 } from "citty";
|
|
5429
|
+
var topCompaniesCommand = defineCommand45({
|
|
5269
5430
|
meta: {
|
|
5270
5431
|
name: "top-companies",
|
|
5271
5432
|
description: `Top companies whose employees saw / clicked / converted on a campaign.
|
|
@@ -5336,7 +5497,7 @@ Examples:
|
|
|
5336
5497
|
});
|
|
5337
5498
|
|
|
5338
5499
|
// src/commands/ads/linkedin/index.ts
|
|
5339
|
-
var linkedinCommand =
|
|
5500
|
+
var linkedinCommand = defineCommand46({
|
|
5340
5501
|
meta: {
|
|
5341
5502
|
name: "linkedin",
|
|
5342
5503
|
description: `LinkedIn Marketing API \u2014 AI-first command surface for B2B ad insights.
|
|
@@ -5388,10 +5549,10 @@ Account ID format:
|
|
|
5388
5549
|
});
|
|
5389
5550
|
|
|
5390
5551
|
// src/commands/ads/meta/index.ts
|
|
5391
|
-
import { defineCommand as
|
|
5552
|
+
import { defineCommand as defineCommand59 } from "citty";
|
|
5392
5553
|
|
|
5393
5554
|
// src/commands/ads/meta/account.ts
|
|
5394
|
-
import { defineCommand as
|
|
5555
|
+
import { defineCommand as defineCommand47 } from "citty";
|
|
5395
5556
|
|
|
5396
5557
|
// src/commands/ads/meta/shared.ts
|
|
5397
5558
|
var DAY_MS4 = 864e5;
|
|
@@ -5470,7 +5631,7 @@ function resolveEffectiveStatus(args) {
|
|
|
5470
5631
|
}
|
|
5471
5632
|
|
|
5472
5633
|
// src/commands/ads/meta/account.ts
|
|
5473
|
-
var accountCommand2 =
|
|
5634
|
+
var accountCommand2 = defineCommand47({
|
|
5474
5635
|
meta: {
|
|
5475
5636
|
name: "account",
|
|
5476
5637
|
description: `Show single Meta ad account detail (currency, timezone, balance, business).
|
|
@@ -5497,8 +5658,8 @@ Examples:
|
|
|
5497
5658
|
});
|
|
5498
5659
|
|
|
5499
5660
|
// src/commands/ads/meta/accounts.ts
|
|
5500
|
-
import { defineCommand as
|
|
5501
|
-
var accountsCommand3 =
|
|
5661
|
+
import { defineCommand as defineCommand48 } from "citty";
|
|
5662
|
+
var accountsCommand3 = defineCommand48({
|
|
5502
5663
|
meta: {
|
|
5503
5664
|
name: "accounts",
|
|
5504
5665
|
description: `List Meta ad accounts in this company's connected scope.
|
|
@@ -5546,8 +5707,8 @@ Examples:
|
|
|
5546
5707
|
});
|
|
5547
5708
|
|
|
5548
5709
|
// src/commands/ads/meta/activities.ts
|
|
5549
|
-
import { defineCommand as
|
|
5550
|
-
var activitiesCommand =
|
|
5710
|
+
import { defineCommand as defineCommand49 } from "citty";
|
|
5711
|
+
var activitiesCommand = defineCommand49({
|
|
5551
5712
|
meta: {
|
|
5552
5713
|
name: "activities",
|
|
5553
5714
|
description: `Audit log of recent ad-account changes (created, paused, edited). Default lookback 7 days,
|
|
@@ -5584,8 +5745,8 @@ Examples:
|
|
|
5584
5745
|
});
|
|
5585
5746
|
|
|
5586
5747
|
// src/commands/ads/meta/ads.ts
|
|
5587
|
-
import { defineCommand as
|
|
5588
|
-
var adsListCommand =
|
|
5748
|
+
import { defineCommand as defineCommand50 } from "citty";
|
|
5749
|
+
var adsListCommand = defineCommand50({
|
|
5589
5750
|
meta: {
|
|
5590
5751
|
name: "ads",
|
|
5591
5752
|
description: `List ads in a Meta ad account. Defaults to ACTIVE only \u2014 pass --all-statuses to widen.
|
|
@@ -5633,8 +5794,8 @@ Examples:
|
|
|
5633
5794
|
});
|
|
5634
5795
|
|
|
5635
5796
|
// src/commands/ads/meta/adsets.ts
|
|
5636
|
-
import { defineCommand as
|
|
5637
|
-
var adsetsCommand =
|
|
5797
|
+
import { defineCommand as defineCommand51 } from "citty";
|
|
5798
|
+
var adsetsCommand = defineCommand51({
|
|
5638
5799
|
meta: {
|
|
5639
5800
|
name: "adsets",
|
|
5640
5801
|
description: `List ad sets in a Meta ad account, optionally scoped to one campaign. Defaults to ACTIVE only.
|
|
@@ -5676,8 +5837,8 @@ Examples:
|
|
|
5676
5837
|
});
|
|
5677
5838
|
|
|
5678
5839
|
// src/commands/ads/meta/audiences.ts
|
|
5679
|
-
import { defineCommand as
|
|
5680
|
-
var audiencesCommand =
|
|
5840
|
+
import { defineCommand as defineCommand52 } from "citty";
|
|
5841
|
+
var audiencesCommand = defineCommand52({
|
|
5681
5842
|
meta: {
|
|
5682
5843
|
name: "audiences",
|
|
5683
5844
|
description: `List custom audiences for a Meta ad account. Includes lookalikes, website-pixel audiences,
|
|
@@ -5712,8 +5873,8 @@ Examples:
|
|
|
5712
5873
|
});
|
|
5713
5874
|
|
|
5714
5875
|
// src/commands/ads/meta/businesses.ts
|
|
5715
|
-
import { defineCommand as
|
|
5716
|
-
var businessesCommand =
|
|
5876
|
+
import { defineCommand as defineCommand53 } from "citty";
|
|
5877
|
+
var businessesCommand = defineCommand53({
|
|
5717
5878
|
meta: {
|
|
5718
5879
|
name: "businesses",
|
|
5719
5880
|
description: `List Meta Business Manager accounts the connected user has access to. Required for ad-studies and product-catalogs commands.
|
|
@@ -5743,8 +5904,8 @@ Examples:
|
|
|
5743
5904
|
});
|
|
5744
5905
|
|
|
5745
5906
|
// src/commands/ads/meta/campaigns.ts
|
|
5746
|
-
import { defineCommand as
|
|
5747
|
-
var campaignsCommand2 =
|
|
5907
|
+
import { defineCommand as defineCommand54 } from "citty";
|
|
5908
|
+
var campaignsCommand2 = defineCommand54({
|
|
5748
5909
|
meta: {
|
|
5749
5910
|
name: "campaigns",
|
|
5750
5911
|
description: `List campaigns for a Meta ad account. Defaults to ACTIVE only \u2014 pass --all-statuses to widen.
|
|
@@ -5788,8 +5949,8 @@ Examples:
|
|
|
5788
5949
|
});
|
|
5789
5950
|
|
|
5790
5951
|
// src/commands/ads/meta/creatives.ts
|
|
5791
|
-
import { defineCommand as
|
|
5792
|
-
var creativesCommand2 =
|
|
5952
|
+
import { defineCommand as defineCommand55 } from "citty";
|
|
5953
|
+
var creativesCommand2 = defineCommand55({
|
|
5793
5954
|
meta: {
|
|
5794
5955
|
name: "creatives",
|
|
5795
5956
|
description: `List ad creatives in an account, or fetch a single creative by ID.
|
|
@@ -5833,7 +5994,7 @@ Examples:
|
|
|
5833
5994
|
});
|
|
5834
5995
|
|
|
5835
5996
|
// src/commands/ads/meta/insights.ts
|
|
5836
|
-
import { defineCommand as
|
|
5997
|
+
import { defineCommand as defineCommand56 } from "citty";
|
|
5837
5998
|
|
|
5838
5999
|
// src/commands/ads/meta/presets.ts
|
|
5839
6000
|
var INSIGHTS_INTENTS = {
|
|
@@ -6038,7 +6199,7 @@ function sortRowsBySpendDesc(rows) {
|
|
|
6038
6199
|
return sb - sa;
|
|
6039
6200
|
});
|
|
6040
6201
|
}
|
|
6041
|
-
var insightsCommand =
|
|
6202
|
+
var insightsCommand = defineCommand56({
|
|
6042
6203
|
meta: {
|
|
6043
6204
|
name: "insights",
|
|
6044
6205
|
description: `Performance reporting \u2014 the main Meta tool for AI agents.
|
|
@@ -6139,8 +6300,8 @@ Async is automatic for heavy queries; pass --async to force it, or --no-async to
|
|
|
6139
6300
|
});
|
|
6140
6301
|
|
|
6141
6302
|
// src/commands/ads/meta/pixels.ts
|
|
6142
|
-
import { defineCommand as
|
|
6143
|
-
var pixelsCommand =
|
|
6303
|
+
import { defineCommand as defineCommand57 } from "citty";
|
|
6304
|
+
var pixelsCommand = defineCommand57({
|
|
6144
6305
|
meta: {
|
|
6145
6306
|
name: "pixels",
|
|
6146
6307
|
description: `List Meta Pixels for an ad account, or fetch firing stats for one pixel.
|
|
@@ -6211,7 +6372,7 @@ function emit(data, args) {
|
|
|
6211
6372
|
|
|
6212
6373
|
// src/commands/ads/meta/preview.ts
|
|
6213
6374
|
import { writeFileSync as writeFileSync3 } from "fs";
|
|
6214
|
-
import { defineCommand as
|
|
6375
|
+
import { defineCommand as defineCommand58 } from "citty";
|
|
6215
6376
|
var VALID_AD_FORMATS = [
|
|
6216
6377
|
"DESKTOP_FEED_STANDARD",
|
|
6217
6378
|
"MOBILE_FEED_STANDARD",
|
|
@@ -6245,7 +6406,7 @@ var VALID_AD_FORMATS = [
|
|
|
6245
6406
|
"MARKETPLACE_MOBILE",
|
|
6246
6407
|
"BIZ_DISCO_FEED_MOBILE"
|
|
6247
6408
|
];
|
|
6248
|
-
var previewCommand =
|
|
6409
|
+
var previewCommand = defineCommand58({
|
|
6249
6410
|
meta: {
|
|
6250
6411
|
name: "preview",
|
|
6251
6412
|
description: `Generate a Meta-hosted preview iframe for a creative or ad. Returns iframe HTML which you
|
|
@@ -6292,7 +6453,7 @@ Examples:
|
|
|
6292
6453
|
});
|
|
6293
6454
|
|
|
6294
6455
|
// src/commands/ads/meta/index.ts
|
|
6295
|
-
var metaCommand =
|
|
6456
|
+
var metaCommand = defineCommand59({
|
|
6296
6457
|
meta: {
|
|
6297
6458
|
name: "meta",
|
|
6298
6459
|
description: `Meta Marketing API \u2014 AI-first command surface (Facebook + Instagram ads).
|
|
@@ -6344,10 +6505,10 @@ Audit & review:
|
|
|
6344
6505
|
});
|
|
6345
6506
|
|
|
6346
6507
|
// src/commands/ads/x/index.ts
|
|
6347
|
-
import { defineCommand as
|
|
6508
|
+
import { defineCommand as defineCommand76 } from "citty";
|
|
6348
6509
|
|
|
6349
6510
|
// src/commands/ads/x/accounts.ts
|
|
6350
|
-
import { defineCommand as
|
|
6511
|
+
import { defineCommand as defineCommand60 } from "citty";
|
|
6351
6512
|
registerSchema({
|
|
6352
6513
|
command: "ads.x.accounts",
|
|
6353
6514
|
description: "List all accessible X Ads accounts. Returns accounts with id (base36), name, approval_status, timezone, currency. Run this first to find account IDs for other commands.",
|
|
@@ -6375,7 +6536,7 @@ function handleAccountsError2(err) {
|
|
|
6375
6536
|
writeAdsJson({ ok: false, error: { code: "NETWORK_ERROR", message: "Unexpected error" } });
|
|
6376
6537
|
process.exit(1);
|
|
6377
6538
|
}
|
|
6378
|
-
var accountsCommand4 =
|
|
6539
|
+
var accountsCommand4 = defineCommand60({
|
|
6379
6540
|
meta: {
|
|
6380
6541
|
name: "accounts",
|
|
6381
6542
|
description: `List accessible X Ads accounts. Returns account IDs needed for all other commands.
|
|
@@ -6415,7 +6576,7 @@ Examples:
|
|
|
6415
6576
|
});
|
|
6416
6577
|
|
|
6417
6578
|
// src/commands/ads/x/active-entities.ts
|
|
6418
|
-
import { defineCommand as
|
|
6579
|
+
import { defineCommand as defineCommand61 } from "citty";
|
|
6419
6580
|
|
|
6420
6581
|
// src/commands/ads/x/error-parser.ts
|
|
6421
6582
|
function mapXErrorCode(message) {
|
|
@@ -6566,7 +6727,7 @@ function parseCsv(v) {
|
|
|
6566
6727
|
const parts = v.split(",").map((s) => s.trim()).filter(Boolean);
|
|
6567
6728
|
return parts.length > 0 ? parts : void 0;
|
|
6568
6729
|
}
|
|
6569
|
-
var activeEntitiesCommand =
|
|
6730
|
+
var activeEntitiesCommand = defineCommand61({
|
|
6570
6731
|
meta: {
|
|
6571
6732
|
name: "active-entities",
|
|
6572
6733
|
description: `List entities with metric activity in a time range.
|
|
@@ -6624,7 +6785,7 @@ Examples:
|
|
|
6624
6785
|
});
|
|
6625
6786
|
|
|
6626
6787
|
// src/commands/ads/x/audiences.ts
|
|
6627
|
-
import { defineCommand as
|
|
6788
|
+
import { defineCommand as defineCommand62 } from "citty";
|
|
6628
6789
|
registerSchema({
|
|
6629
6790
|
command: "ads.x.audiences",
|
|
6630
6791
|
description: "List custom audiences for an X Ads account. Returns id, name, audience_size, audience_type, targetable status. Audiences need 100+ active users in the past 90 days to be targetable.",
|
|
@@ -6633,7 +6794,7 @@ registerSchema({
|
|
|
6633
6794
|
"no-cache": { type: "boolean", description: "Skip cache", required: false }
|
|
6634
6795
|
}
|
|
6635
6796
|
});
|
|
6636
|
-
var audiencesCommand2 =
|
|
6797
|
+
var audiencesCommand2 = defineCommand62({
|
|
6637
6798
|
meta: {
|
|
6638
6799
|
name: "audiences",
|
|
6639
6800
|
description: `List X Ads custom audiences.
|
|
@@ -6682,7 +6843,7 @@ Examples:
|
|
|
6682
6843
|
});
|
|
6683
6844
|
|
|
6684
6845
|
// src/commands/ads/x/campaigns.ts
|
|
6685
|
-
import { defineCommand as
|
|
6846
|
+
import { defineCommand as defineCommand63 } from "citty";
|
|
6686
6847
|
|
|
6687
6848
|
// src/commands/ads/x/run-list.ts
|
|
6688
6849
|
function buildCleanParams(opts) {
|
|
@@ -6745,7 +6906,7 @@ registerSchema({
|
|
|
6745
6906
|
"no-cache": { type: "boolean", description: "Skip cache", required: false }
|
|
6746
6907
|
}
|
|
6747
6908
|
});
|
|
6748
|
-
var campaignsCommand3 =
|
|
6909
|
+
var campaignsCommand3 = defineCommand63({
|
|
6749
6910
|
meta: {
|
|
6750
6911
|
name: "campaigns",
|
|
6751
6912
|
description: `List X Ads campaigns. Returns budget, schedule, funding instrument, status.
|
|
@@ -6787,7 +6948,7 @@ Examples:
|
|
|
6787
6948
|
});
|
|
6788
6949
|
|
|
6789
6950
|
// src/commands/ads/x/cards.ts
|
|
6790
|
-
import { defineCommand as
|
|
6951
|
+
import { defineCommand as defineCommand64 } from "citty";
|
|
6791
6952
|
registerSchema({
|
|
6792
6953
|
command: "ads.x.cards",
|
|
6793
6954
|
description: "List website cards, video cards, and carousels for an X Ads account.",
|
|
@@ -6796,7 +6957,7 @@ registerSchema({
|
|
|
6796
6957
|
"no-cache": { type: "boolean", description: "Skip cache", required: false }
|
|
6797
6958
|
}
|
|
6798
6959
|
});
|
|
6799
|
-
var cardsCommand =
|
|
6960
|
+
var cardsCommand = defineCommand64({
|
|
6800
6961
|
meta: {
|
|
6801
6962
|
name: "cards",
|
|
6802
6963
|
description: `List X Ads cards (rich creatives).
|
|
@@ -6845,7 +7006,7 @@ Examples:
|
|
|
6845
7006
|
});
|
|
6846
7007
|
|
|
6847
7008
|
// src/commands/ads/x/funding.ts
|
|
6848
|
-
import { defineCommand as
|
|
7009
|
+
import { defineCommand as defineCommand65 } from "citty";
|
|
6849
7010
|
registerSchema({
|
|
6850
7011
|
command: "ads.x.funding",
|
|
6851
7012
|
description: "List funding instruments for an X Ads account. Returns id, type, currency, credit_limit_local_micro, funded_amount_local_micro, status. Falls back to BAKER_X_ADS_ACCOUNT_ID env var.",
|
|
@@ -6854,7 +7015,7 @@ registerSchema({
|
|
|
6854
7015
|
"no-cache": { type: "boolean", description: "Skip cache", required: false }
|
|
6855
7016
|
}
|
|
6856
7017
|
});
|
|
6857
|
-
var fundingCommand =
|
|
7018
|
+
var fundingCommand = defineCommand65({
|
|
6858
7019
|
meta: {
|
|
6859
7020
|
name: "funding",
|
|
6860
7021
|
description: `List funding instruments for an X Ads account.
|
|
@@ -6903,7 +7064,7 @@ Examples:
|
|
|
6903
7064
|
});
|
|
6904
7065
|
|
|
6905
7066
|
// src/commands/ads/x/line-items.ts
|
|
6906
|
-
import { defineCommand as
|
|
7067
|
+
import { defineCommand as defineCommand66 } from "citty";
|
|
6907
7068
|
registerSchema({
|
|
6908
7069
|
command: "ads.x.lineItems",
|
|
6909
7070
|
description: "List line items (ad groups) for an X Ads account. Returns bid, product_type, objective, placements, schedule. Filter by campaign-ids or line-item-ids (CSV).",
|
|
@@ -6915,7 +7076,7 @@ registerSchema({
|
|
|
6915
7076
|
"no-cache": { type: "boolean", description: "Skip cache", required: false }
|
|
6916
7077
|
}
|
|
6917
7078
|
});
|
|
6918
|
-
var lineItemsCommand =
|
|
7079
|
+
var lineItemsCommand = defineCommand66({
|
|
6919
7080
|
meta: {
|
|
6920
7081
|
name: "line-items",
|
|
6921
7082
|
description: `List X Ads line items (ad groups).
|
|
@@ -6956,7 +7117,7 @@ Examples:
|
|
|
6956
7117
|
});
|
|
6957
7118
|
|
|
6958
7119
|
// src/commands/ads/x/media.ts
|
|
6959
|
-
import { defineCommand as
|
|
7120
|
+
import { defineCommand as defineCommand67 } from "citty";
|
|
6960
7121
|
registerSchema({
|
|
6961
7122
|
command: "ads.x.media",
|
|
6962
7123
|
description: "List media assets in the X Ads media library (images, GIFs, videos). Filter by media-type (IMAGE, GIF, VIDEO).",
|
|
@@ -6966,7 +7127,7 @@ registerSchema({
|
|
|
6966
7127
|
"no-cache": { type: "boolean", description: "Skip cache", required: false }
|
|
6967
7128
|
}
|
|
6968
7129
|
});
|
|
6969
|
-
var mediaCommand =
|
|
7130
|
+
var mediaCommand = defineCommand67({
|
|
6970
7131
|
meta: {
|
|
6971
7132
|
name: "media",
|
|
6972
7133
|
description: `List media assets in the X Ads media library.
|
|
@@ -7018,7 +7179,7 @@ Examples:
|
|
|
7018
7179
|
});
|
|
7019
7180
|
|
|
7020
7181
|
// src/commands/ads/x/promoted-tweets.ts
|
|
7021
|
-
import { defineCommand as
|
|
7182
|
+
import { defineCommand as defineCommand68 } from "citty";
|
|
7022
7183
|
registerSchema({
|
|
7023
7184
|
command: "ads.x.promotedTweets",
|
|
7024
7185
|
description: "List promoted tweets for an X Ads account. Returns id, line_item_id, tweet_id, approval_status. Filter by line-item-ids (CSV).",
|
|
@@ -7029,7 +7190,7 @@ registerSchema({
|
|
|
7029
7190
|
"no-cache": { type: "boolean", description: "Skip cache", required: false }
|
|
7030
7191
|
}
|
|
7031
7192
|
});
|
|
7032
|
-
var promotedTweetsCommand =
|
|
7193
|
+
var promotedTweetsCommand = defineCommand68({
|
|
7033
7194
|
meta: {
|
|
7034
7195
|
name: "promoted-tweets",
|
|
7035
7196
|
description: `List X Ads promoted tweets.
|
|
@@ -7083,11 +7244,11 @@ Examples:
|
|
|
7083
7244
|
});
|
|
7084
7245
|
|
|
7085
7246
|
// src/commands/ads/x/stats/index.ts
|
|
7086
|
-
import { defineCommand as
|
|
7247
|
+
import { defineCommand as defineCommand73 } from "citty";
|
|
7087
7248
|
|
|
7088
7249
|
// src/commands/ads/x/stats/job.ts
|
|
7089
7250
|
import { gunzipSync } from "zlib";
|
|
7090
|
-
import { defineCommand as
|
|
7251
|
+
import { defineCommand as defineCommand69 } from "citty";
|
|
7091
7252
|
var POLL_INTERVAL_MS2 = 1e4;
|
|
7092
7253
|
var DEADLINE_MS = 12 * 60 * 1e3;
|
|
7093
7254
|
var RESULT_CACHE_TTL_MS = 6 * 60 * 60 * 1e3;
|
|
@@ -7157,7 +7318,7 @@ async function pollUntilDone(accountId, jobId) {
|
|
|
7157
7318
|
function buildCacheKey(body) {
|
|
7158
7319
|
return `stats-job:${JSON.stringify(body)}`;
|
|
7159
7320
|
}
|
|
7160
|
-
var statsJobCommand =
|
|
7321
|
+
var statsJobCommand = defineCommand69({
|
|
7161
7322
|
meta: {
|
|
7162
7323
|
name: "job",
|
|
7163
7324
|
description: `Async X Ads stats job, sync from the CLI's perspective. Creates \u2192 polls \u2192 downloads \u2192 returns.
|
|
@@ -7262,7 +7423,7 @@ For fine-grained control (don't wait, poll yourself), use:
|
|
|
7262
7423
|
});
|
|
7263
7424
|
|
|
7264
7425
|
// src/commands/ads/x/stats/job-create.ts
|
|
7265
|
-
import { defineCommand as
|
|
7426
|
+
import { defineCommand as defineCommand70 } from "citty";
|
|
7266
7427
|
registerSchema({
|
|
7267
7428
|
command: "ads.x.statsJobCreate",
|
|
7268
7429
|
description: "Create an asynchronous X Ads stats job (range up to 90 days non-segmented, 45 days segmented). Returns a job id; poll with `stats job-status`. Times must be ISO 8601 hour-aligned.",
|
|
@@ -7285,7 +7446,7 @@ function parseCsv3(v) {
|
|
|
7285
7446
|
const parts = v.split(",").map((s) => s.trim()).filter(Boolean);
|
|
7286
7447
|
return parts.length > 0 ? parts : void 0;
|
|
7287
7448
|
}
|
|
7288
|
-
var statsJobCreateCommand =
|
|
7449
|
+
var statsJobCreateCommand = defineCommand70({
|
|
7289
7450
|
meta: {
|
|
7290
7451
|
name: "job-create",
|
|
7291
7452
|
description: `Create an async X Ads stats job (up to 90 days, supports segmentation).
|
|
@@ -7348,7 +7509,7 @@ Examples:
|
|
|
7348
7509
|
});
|
|
7349
7510
|
|
|
7350
7511
|
// src/commands/ads/x/stats/job-status.ts
|
|
7351
|
-
import { defineCommand as
|
|
7512
|
+
import { defineCommand as defineCommand71 } from "citty";
|
|
7352
7513
|
registerSchema({
|
|
7353
7514
|
command: "ads.x.statsJobStatus",
|
|
7354
7515
|
description: "Check the status of one or more X Ads stats jobs. Returns status (PROCESSING|SUCCESS|FAILED) and a downloadable url when SUCCESS. Pass --job-id or --job-ids (CSV).",
|
|
@@ -7358,7 +7519,7 @@ registerSchema({
|
|
|
7358
7519
|
"job-ids": { type: "string", description: "CSV of job IDs", required: false }
|
|
7359
7520
|
}
|
|
7360
7521
|
});
|
|
7361
|
-
var statsJobStatusCommand =
|
|
7522
|
+
var statsJobStatusCommand = defineCommand71({
|
|
7362
7523
|
meta: {
|
|
7363
7524
|
name: "job-status",
|
|
7364
7525
|
description: `Poll the status of an async X Ads stats job.
|
|
@@ -7399,7 +7560,7 @@ Examples:
|
|
|
7399
7560
|
});
|
|
7400
7561
|
|
|
7401
7562
|
// src/commands/ads/x/stats/sync.ts
|
|
7402
|
-
import { defineCommand as
|
|
7563
|
+
import { defineCommand as defineCommand72 } from "citty";
|
|
7403
7564
|
|
|
7404
7565
|
// src/commands/ads/x/presets.ts
|
|
7405
7566
|
var X_STATS_PRESETS = [
|
|
@@ -7558,7 +7719,7 @@ async function runSync(args, q) {
|
|
|
7558
7719
|
process.exit(1);
|
|
7559
7720
|
}
|
|
7560
7721
|
}
|
|
7561
|
-
var statsSyncCommand =
|
|
7722
|
+
var statsSyncCommand = defineCommand72({
|
|
7562
7723
|
meta: {
|
|
7563
7724
|
name: "sync",
|
|
7564
7725
|
description: `Synchronous X Ads analytics (max 7-day window).
|
|
@@ -7601,7 +7762,7 @@ Examples:
|
|
|
7601
7762
|
});
|
|
7602
7763
|
|
|
7603
7764
|
// src/commands/ads/x/stats/index.ts
|
|
7604
|
-
var statsCommand =
|
|
7765
|
+
var statsCommand = defineCommand73({
|
|
7605
7766
|
meta: {
|
|
7606
7767
|
name: "stats",
|
|
7607
7768
|
description: `X Ads analytics. Sync (\u22647 days, no segmentation) or async jobs (\u226490 days, segmentable).
|
|
@@ -7629,7 +7790,7 @@ Examples:
|
|
|
7629
7790
|
});
|
|
7630
7791
|
|
|
7631
7792
|
// src/commands/ads/x/targeting-constants.ts
|
|
7632
|
-
import { defineCommand as
|
|
7793
|
+
import { defineCommand as defineCommand74 } from "citty";
|
|
7633
7794
|
var ALLOWED_CONSTANTS = [
|
|
7634
7795
|
"locations",
|
|
7635
7796
|
"interests",
|
|
@@ -7657,7 +7818,7 @@ registerSchema({
|
|
|
7657
7818
|
"no-cache": { type: "boolean", description: "Skip cache", required: false }
|
|
7658
7819
|
}
|
|
7659
7820
|
});
|
|
7660
|
-
var targetingConstantsCommand =
|
|
7821
|
+
var targetingConstantsCommand = defineCommand74({
|
|
7661
7822
|
meta: {
|
|
7662
7823
|
name: "targeting-constants",
|
|
7663
7824
|
description: `Lookup X Ads targeting constants.
|
|
@@ -7707,7 +7868,7 @@ Examples:
|
|
|
7707
7868
|
});
|
|
7708
7869
|
|
|
7709
7870
|
// src/commands/ads/x/targeting-criteria.ts
|
|
7710
|
-
import { defineCommand as
|
|
7871
|
+
import { defineCommand as defineCommand75 } from "citty";
|
|
7711
7872
|
registerSchema({
|
|
7712
7873
|
command: "ads.x.targetingCriteria",
|
|
7713
7874
|
description: "List targeting criteria attached to line items in an X Ads account. Returns targeting_type, targeting_value, name, operator_type per criterion. Filter by line-item-ids.",
|
|
@@ -7717,7 +7878,7 @@ registerSchema({
|
|
|
7717
7878
|
"no-cache": { type: "boolean", description: "Skip cache", required: false }
|
|
7718
7879
|
}
|
|
7719
7880
|
});
|
|
7720
|
-
var targetingCriteriaCommand =
|
|
7881
|
+
var targetingCriteriaCommand = defineCommand75({
|
|
7721
7882
|
meta: {
|
|
7722
7883
|
name: "targeting-criteria",
|
|
7723
7884
|
description: `List targeting criteria attached to line items.
|
|
@@ -7768,7 +7929,7 @@ Examples:
|
|
|
7768
7929
|
});
|
|
7769
7930
|
|
|
7770
7931
|
// src/commands/ads/x/index.ts
|
|
7771
|
-
var xCommand =
|
|
7932
|
+
var xCommand = defineCommand76({
|
|
7772
7933
|
meta: {
|
|
7773
7934
|
name: "x",
|
|
7774
7935
|
description: `X (Twitter) Ads commands. Read campaigns, line items, promoted tweets, creatives, audiences, and analytics.
|
|
@@ -7806,7 +7967,7 @@ The CLI auto-detects --account-id when exactly one X Ads account is connected, o
|
|
|
7806
7967
|
});
|
|
7807
7968
|
|
|
7808
7969
|
// src/commands/ads/index.ts
|
|
7809
|
-
var adsCommand =
|
|
7970
|
+
var adsCommand = defineCommand77({
|
|
7810
7971
|
meta: {
|
|
7811
7972
|
name: "ads",
|
|
7812
7973
|
description: `Ad platform commands. Each platform exposes its own native command surface \u2014 no forced parity.
|
|
@@ -7836,11 +7997,11 @@ Examples:
|
|
|
7836
7997
|
});
|
|
7837
7998
|
|
|
7838
7999
|
// src/commands/canvas/index.ts
|
|
7839
|
-
import { defineCommand as
|
|
8000
|
+
import { defineCommand as defineCommand84 } from "citty";
|
|
7840
8001
|
|
|
7841
8002
|
// src/commands/canvas/catalog.ts
|
|
7842
|
-
import { defineCommand as
|
|
7843
|
-
var catalogCommand =
|
|
8003
|
+
import { defineCommand as defineCommand78 } from "citty";
|
|
8004
|
+
var catalogCommand = defineCommand78({
|
|
7844
8005
|
meta: {
|
|
7845
8006
|
name: "catalog",
|
|
7846
8007
|
description: "Print the agent-facing node catalog (JSON Schema). Includes every registered node grouped by category."
|
|
@@ -7857,9 +8018,9 @@ import { execFile } from "child_process";
|
|
|
7857
8018
|
import { readdir, readFile, stat } from "fs/promises";
|
|
7858
8019
|
import path from "path";
|
|
7859
8020
|
import { promisify } from "util";
|
|
7860
|
-
import { defineCommand as
|
|
8021
|
+
import { defineCommand as defineCommand79 } from "citty";
|
|
7861
8022
|
var execFileAsync = promisify(execFile);
|
|
7862
|
-
var inspectCommand =
|
|
8023
|
+
var inspectCommand = defineCommand79({
|
|
7863
8024
|
meta: {
|
|
7864
8025
|
name: "inspect",
|
|
7865
8026
|
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."
|
|
@@ -7968,7 +8129,7 @@ async function probeDuration(filePath) {
|
|
|
7968
8129
|
// src/commands/canvas/run.ts
|
|
7969
8130
|
import { readFile as readFile2 } from "fs/promises";
|
|
7970
8131
|
import path2 from "path";
|
|
7971
|
-
import { defineCommand as
|
|
8132
|
+
import { defineCommand as defineCommand80 } from "citty";
|
|
7972
8133
|
|
|
7973
8134
|
// src/commands/canvas/placeholders.ts
|
|
7974
8135
|
function unsuppliedPlaceholderAssets(canvas) {
|
|
@@ -7987,7 +8148,7 @@ function unsuppliedPlaceholderAssets(canvas) {
|
|
|
7987
8148
|
}
|
|
7988
8149
|
|
|
7989
8150
|
// src/commands/canvas/run.ts
|
|
7990
|
-
var runCommand =
|
|
8151
|
+
var runCommand = defineCommand80({
|
|
7991
8152
|
meta: { name: "run", description: "Validate and execute a canvas JSON file." },
|
|
7992
8153
|
args: {
|
|
7993
8154
|
file: { type: "positional", required: true, description: "Path to canvas JSON" },
|
|
@@ -8072,7 +8233,7 @@ var runCommand = defineCommand76({
|
|
|
8072
8233
|
// src/commands/canvas/scaffold-static-ad.ts
|
|
8073
8234
|
import { readFile as readFile3, writeFile } from "fs/promises";
|
|
8074
8235
|
import path3 from "path";
|
|
8075
|
-
import { defineCommand as
|
|
8236
|
+
import { defineCommand as defineCommand81 } from "citty";
|
|
8076
8237
|
|
|
8077
8238
|
// src/engine/scaffold/staticAd.ts
|
|
8078
8239
|
import { z as z2 } from "zod";
|
|
@@ -8391,7 +8552,7 @@ async function runVisionPasses(canvas) {
|
|
|
8391
8552
|
return fail("read_outputs", e instanceof Error ? e.message : String(e));
|
|
8392
8553
|
}
|
|
8393
8554
|
}
|
|
8394
|
-
var scaffoldStaticAdCommand =
|
|
8555
|
+
var scaffoldStaticAdCommand = defineCommand81({
|
|
8395
8556
|
meta: {
|
|
8396
8557
|
name: "scaffold-static-ad",
|
|
8397
8558
|
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. Edit prompt.json and drop the real assets, then `baker canvas run` it."
|
|
@@ -8485,7 +8646,7 @@ var scaffoldStaticAdCommand = defineCommand77({
|
|
|
8485
8646
|
// src/commands/canvas/scaffold-video.ts
|
|
8486
8647
|
import { cp, mkdir, readFile as readFile5, writeFile as writeFile2 } from "fs/promises";
|
|
8487
8648
|
import path5 from "path";
|
|
8488
|
-
import { defineCommand as
|
|
8649
|
+
import { defineCommand as defineCommand82 } from "citty";
|
|
8489
8650
|
|
|
8490
8651
|
// src/engine/nodes/local/lib/sceneDetect.ts
|
|
8491
8652
|
import { execFile as execFile2 } from "child_process";
|
|
@@ -11136,7 +11297,7 @@ async function runAnalysisPasses(deconstructCanvas, selectModel) {
|
|
|
11136
11297
|
return fail2("deconstruct", e instanceof Error ? e.message : String(e));
|
|
11137
11298
|
}
|
|
11138
11299
|
}
|
|
11139
|
-
var scaffoldVideoCommand =
|
|
11300
|
+
var scaffoldVideoCommand = defineCommand82({
|
|
11140
11301
|
meta: {
|
|
11141
11302
|
name: "scaffold-video",
|
|
11142
11303
|
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 prompt.json as the editable 'prompt') 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 prompt.json, drop the real source images, then `baker canvas run`."
|
|
@@ -11280,8 +11441,8 @@ var scaffoldVideoCommand = defineCommand78({
|
|
|
11280
11441
|
// src/commands/canvas/validate.ts
|
|
11281
11442
|
import { readFile as readFile6 } from "fs/promises";
|
|
11282
11443
|
import path6 from "path";
|
|
11283
|
-
import { defineCommand as
|
|
11284
|
-
var validateCommand =
|
|
11444
|
+
import { defineCommand as defineCommand83 } from "citty";
|
|
11445
|
+
var validateCommand = defineCommand83({
|
|
11285
11446
|
meta: {
|
|
11286
11447
|
name: "validate",
|
|
11287
11448
|
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)."
|
|
@@ -11323,7 +11484,7 @@ var validateCommand = defineCommand79({
|
|
|
11323
11484
|
});
|
|
11324
11485
|
|
|
11325
11486
|
// src/commands/canvas/index.ts
|
|
11326
|
-
var canvasCommand =
|
|
11487
|
+
var canvasCommand = defineCommand84({
|
|
11327
11488
|
meta: {
|
|
11328
11489
|
name: "canvas",
|
|
11329
11490
|
description: `Run Baker creative canvas JSON files locally. Local nodes execute in-process; remote nodes POST to the Convex backend gateway.
|
|
@@ -11349,10 +11510,10 @@ Subcommands:
|
|
|
11349
11510
|
});
|
|
11350
11511
|
|
|
11351
11512
|
// src/commands/ga4/index.ts
|
|
11352
|
-
import { defineCommand as
|
|
11513
|
+
import { defineCommand as defineCommand88 } from "citty";
|
|
11353
11514
|
|
|
11354
11515
|
// src/commands/ga4/audit.ts
|
|
11355
|
-
import { defineCommand as
|
|
11516
|
+
import { defineCommand as defineCommand85 } from "citty";
|
|
11356
11517
|
|
|
11357
11518
|
// src/commands/ga4/resolve.ts
|
|
11358
11519
|
async function fetchProperties(useCache = true) {
|
|
@@ -11415,7 +11576,7 @@ registerSchema({
|
|
|
11415
11576
|
"no-cache": { type: "boolean", description: "Skip cache, hit API directly", required: false }
|
|
11416
11577
|
}
|
|
11417
11578
|
});
|
|
11418
|
-
var auditCommand2 =
|
|
11579
|
+
var auditCommand2 = defineCommand85({
|
|
11419
11580
|
meta: {
|
|
11420
11581
|
name: "audit",
|
|
11421
11582
|
description: `Run all GA4 admin health checks. Returns property config with playbook warnings.
|
|
@@ -11467,7 +11628,7 @@ Examples:
|
|
|
11467
11628
|
});
|
|
11468
11629
|
|
|
11469
11630
|
// src/commands/ga4/properties.ts
|
|
11470
|
-
import { defineCommand as
|
|
11631
|
+
import { defineCommand as defineCommand86 } from "citty";
|
|
11471
11632
|
registerSchema({
|
|
11472
11633
|
command: "ga4.properties",
|
|
11473
11634
|
description: "List all accessible GA4 properties. Returns property IDs needed for query and audit commands. Run this first to find property IDs.",
|
|
@@ -11475,7 +11636,7 @@ registerSchema({
|
|
|
11475
11636
|
"no-cache": { type: "boolean", description: "Skip cache, hit API directly", required: false }
|
|
11476
11637
|
}
|
|
11477
11638
|
});
|
|
11478
|
-
var propertiesCommand =
|
|
11639
|
+
var propertiesCommand = defineCommand86({
|
|
11479
11640
|
meta: {
|
|
11480
11641
|
name: "properties",
|
|
11481
11642
|
description: `List accessible GA4 properties.
|
|
@@ -11525,7 +11686,7 @@ Examples:
|
|
|
11525
11686
|
// src/commands/ga4/query.ts
|
|
11526
11687
|
import { appendFileSync as appendFileSync2, existsSync as existsSync4, readFileSync as readFileSync6, writeFileSync as writeFileSync4 } from "fs";
|
|
11527
11688
|
import { resolve as resolve2 } from "path";
|
|
11528
|
-
import { defineCommand as
|
|
11689
|
+
import { defineCommand as defineCommand87 } from "citty";
|
|
11529
11690
|
|
|
11530
11691
|
// src/commands/ga4/presets.ts
|
|
11531
11692
|
var GA4_PRESETS = [
|
|
@@ -11657,7 +11818,7 @@ function handleError(err) {
|
|
|
11657
11818
|
});
|
|
11658
11819
|
process.exit(1);
|
|
11659
11820
|
}
|
|
11660
|
-
var queryCommand2 =
|
|
11821
|
+
var queryCommand2 = defineCommand87({
|
|
11661
11822
|
meta: {
|
|
11662
11823
|
name: "query",
|
|
11663
11824
|
description: `Run GA4 Data API reports. Preset-first with free-form escape hatch.
|
|
@@ -11728,7 +11889,7 @@ Free-form (escape hatch):
|
|
|
11728
11889
|
});
|
|
11729
11890
|
|
|
11730
11891
|
// src/commands/ga4/index.ts
|
|
11731
|
-
var ga4Command =
|
|
11892
|
+
var ga4Command = defineCommand88({
|
|
11732
11893
|
meta: {
|
|
11733
11894
|
name: "ga4",
|
|
11734
11895
|
description: `Google Analytics 4 commands. Audit property config, run playbook-aligned reports.
|
|
@@ -11751,12 +11912,12 @@ Examples:
|
|
|
11751
11912
|
});
|
|
11752
11913
|
|
|
11753
11914
|
// src/commands/gsc/index.ts
|
|
11754
|
-
import { defineCommand as
|
|
11915
|
+
import { defineCommand as defineCommand92 } from "citty";
|
|
11755
11916
|
|
|
11756
11917
|
// src/commands/gsc/query.ts
|
|
11757
11918
|
import { appendFileSync as appendFileSync3, existsSync as existsSync5, readFileSync as readFileSync7, writeFileSync as writeFileSync5 } from "fs";
|
|
11758
11919
|
import { resolve as resolve3 } from "path";
|
|
11759
|
-
import { defineCommand as
|
|
11920
|
+
import { defineCommand as defineCommand89 } from "citty";
|
|
11760
11921
|
|
|
11761
11922
|
// src/commands/gsc/presets.ts
|
|
11762
11923
|
var GSC_PRESETS = [
|
|
@@ -11944,7 +12105,7 @@ function handleError2(err) {
|
|
|
11944
12105
|
});
|
|
11945
12106
|
process.exit(1);
|
|
11946
12107
|
}
|
|
11947
|
-
var queryCommand3 =
|
|
12108
|
+
var queryCommand3 = defineCommand89({
|
|
11948
12109
|
meta: {
|
|
11949
12110
|
name: "query",
|
|
11950
12111
|
description: `Run GSC Search Analytics queries. Preset-first with free-form escape hatch.
|
|
@@ -12022,7 +12183,7 @@ Free-form (escape hatch):
|
|
|
12022
12183
|
});
|
|
12023
12184
|
|
|
12024
12185
|
// src/commands/gsc/sitemaps.ts
|
|
12025
|
-
import { defineCommand as
|
|
12186
|
+
import { defineCommand as defineCommand90 } from "citty";
|
|
12026
12187
|
registerSchema({
|
|
12027
12188
|
command: "gsc.sitemaps",
|
|
12028
12189
|
description: "List sitemaps for a Search Console site. Check sitemap health and errors.",
|
|
@@ -12031,7 +12192,7 @@ registerSchema({
|
|
|
12031
12192
|
"no-cache": { type: "boolean", description: "Skip cache, hit API directly", required: false }
|
|
12032
12193
|
}
|
|
12033
12194
|
});
|
|
12034
|
-
var sitemapsCommand =
|
|
12195
|
+
var sitemapsCommand = defineCommand90({
|
|
12035
12196
|
meta: {
|
|
12036
12197
|
name: "sitemaps",
|
|
12037
12198
|
description: `List sitemaps for a site. Check health and errors.
|
|
@@ -12081,7 +12242,7 @@ Examples:
|
|
|
12081
12242
|
});
|
|
12082
12243
|
|
|
12083
12244
|
// src/commands/gsc/sites.ts
|
|
12084
|
-
import { defineCommand as
|
|
12245
|
+
import { defineCommand as defineCommand91 } from "citty";
|
|
12085
12246
|
registerSchema({
|
|
12086
12247
|
command: "gsc.sites",
|
|
12087
12248
|
description: "List all verified Google Search Console sites. Returns site URLs needed for query and sitemaps commands.",
|
|
@@ -12089,7 +12250,7 @@ registerSchema({
|
|
|
12089
12250
|
"no-cache": { type: "boolean", description: "Skip cache, hit API directly", required: false }
|
|
12090
12251
|
}
|
|
12091
12252
|
});
|
|
12092
|
-
var sitesCommand =
|
|
12253
|
+
var sitesCommand = defineCommand91({
|
|
12093
12254
|
meta: {
|
|
12094
12255
|
name: "sites",
|
|
12095
12256
|
description: `List verified Search Console sites.
|
|
@@ -12137,7 +12298,7 @@ Examples:
|
|
|
12137
12298
|
});
|
|
12138
12299
|
|
|
12139
12300
|
// src/commands/gsc/index.ts
|
|
12140
|
-
var gscCommand =
|
|
12301
|
+
var gscCommand = defineCommand92({
|
|
12141
12302
|
meta: {
|
|
12142
12303
|
name: "gsc",
|
|
12143
12304
|
description: `Google Search Console commands. PPC-SEO arbitrage, brand halo analysis, negative keyword discovery.
|
|
@@ -12160,10 +12321,10 @@ Examples:
|
|
|
12160
12321
|
});
|
|
12161
12322
|
|
|
12162
12323
|
// src/commands/images/index.ts
|
|
12163
|
-
import { defineCommand as
|
|
12324
|
+
import { defineCommand as defineCommand116 } from "citty";
|
|
12164
12325
|
|
|
12165
12326
|
// src/commands/images/crop.ts
|
|
12166
|
-
import { defineCommand as
|
|
12327
|
+
import { defineCommand as defineCommand93 } from "citty";
|
|
12167
12328
|
|
|
12168
12329
|
// src/lib/image/crop-sprite.ts
|
|
12169
12330
|
import sharp from "sharp";
|
|
@@ -12288,7 +12449,7 @@ function emitError2(err) {
|
|
|
12288
12449
|
}
|
|
12289
12450
|
process.exit(1);
|
|
12290
12451
|
}
|
|
12291
|
-
var cropCommand =
|
|
12452
|
+
var cropCommand = defineCommand93({
|
|
12292
12453
|
meta: {
|
|
12293
12454
|
name: "crop",
|
|
12294
12455
|
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"
|
|
@@ -12324,7 +12485,7 @@ var cropCommand = defineCommand89({
|
|
|
12324
12485
|
});
|
|
12325
12486
|
|
|
12326
12487
|
// src/commands/images/delete.ts
|
|
12327
|
-
import { defineCommand as
|
|
12488
|
+
import { defineCommand as defineCommand94 } from "citty";
|
|
12328
12489
|
registerSchema({
|
|
12329
12490
|
command: "images.delete",
|
|
12330
12491
|
description: "Delete an image by ID",
|
|
@@ -12338,7 +12499,7 @@ registerSchema({
|
|
|
12338
12499
|
}
|
|
12339
12500
|
}
|
|
12340
12501
|
});
|
|
12341
|
-
var deleteCommand =
|
|
12502
|
+
var deleteCommand = defineCommand94({
|
|
12342
12503
|
meta: {
|
|
12343
12504
|
name: "delete",
|
|
12344
12505
|
description: "Delete an image by ID. Use --dry-run to preview. Example: baker images delete j571abc123 --dry-run"
|
|
@@ -12379,7 +12540,7 @@ var deleteCommand = defineCommand90({
|
|
|
12379
12540
|
});
|
|
12380
12541
|
|
|
12381
12542
|
// src/commands/images/dimensions.ts
|
|
12382
|
-
import { defineCommand as
|
|
12543
|
+
import { defineCommand as defineCommand95 } from "citty";
|
|
12383
12544
|
|
|
12384
12545
|
// src/lib/image/dimensions.ts
|
|
12385
12546
|
import { imageSize } from "image-size";
|
|
@@ -12402,7 +12563,7 @@ registerSchema({
|
|
|
12402
12563
|
target: { type: "string", description: "Local file path or remote http(s) URL", required: true }
|
|
12403
12564
|
}
|
|
12404
12565
|
});
|
|
12405
|
-
var dimensionsCommand =
|
|
12566
|
+
var dimensionsCommand = defineCommand95({
|
|
12406
12567
|
meta: {
|
|
12407
12568
|
name: "dimensions",
|
|
12408
12569
|
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"
|
|
@@ -12446,7 +12607,7 @@ var dimensionsCommand = defineCommand91({
|
|
|
12446
12607
|
});
|
|
12447
12608
|
|
|
12448
12609
|
// src/commands/images/extract.ts
|
|
12449
|
-
import { defineCommand as
|
|
12610
|
+
import { defineCommand as defineCommand96 } from "citty";
|
|
12450
12611
|
registerSchema({
|
|
12451
12612
|
command: "images.extract",
|
|
12452
12613
|
description: "Extract images from a URL via Firecrawl (formats: images).",
|
|
@@ -12462,7 +12623,7 @@ registerSchema({
|
|
|
12462
12623
|
}
|
|
12463
12624
|
}
|
|
12464
12625
|
});
|
|
12465
|
-
var extractCommand =
|
|
12626
|
+
var extractCommand = defineCommand96({
|
|
12466
12627
|
meta: {
|
|
12467
12628
|
name: "extract",
|
|
12468
12629
|
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"
|
|
@@ -12500,7 +12661,7 @@ var extractCommand = defineCommand92({
|
|
|
12500
12661
|
});
|
|
12501
12662
|
|
|
12502
12663
|
// src/commands/images/find.ts
|
|
12503
|
-
import { defineCommand as
|
|
12664
|
+
import { defineCommand as defineCommand97 } from "citty";
|
|
12504
12665
|
registerSchema({
|
|
12505
12666
|
command: "images.find",
|
|
12506
12667
|
description: "Fanout image search: library first, then opted-in external providers.",
|
|
@@ -12532,7 +12693,7 @@ registerSchema({
|
|
|
12532
12693
|
}
|
|
12533
12694
|
}
|
|
12534
12695
|
});
|
|
12535
|
-
var findCommand =
|
|
12696
|
+
var findCommand = defineCommand97({
|
|
12536
12697
|
meta: {
|
|
12537
12698
|
name: "find",
|
|
12538
12699
|
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"
|
|
@@ -12579,7 +12740,7 @@ var findCommand = defineCommand93({
|
|
|
12579
12740
|
|
|
12580
12741
|
// src/commands/images/generate.ts
|
|
12581
12742
|
import { readFile as readFile8 } from "fs/promises";
|
|
12582
|
-
import { defineCommand as
|
|
12743
|
+
import { defineCommand as defineCommand98 } from "citty";
|
|
12583
12744
|
import sharp2 from "sharp";
|
|
12584
12745
|
var GENERATE_TIMEOUT_MS = 18e4;
|
|
12585
12746
|
var REFERENCE_MAX_EDGE = 1536;
|
|
@@ -12675,7 +12836,7 @@ async function resolveReferences(spec) {
|
|
|
12675
12836
|
}
|
|
12676
12837
|
return out;
|
|
12677
12838
|
}
|
|
12678
|
-
var generateCommand =
|
|
12839
|
+
var generateCommand = defineCommand98({
|
|
12679
12840
|
meta: {
|
|
12680
12841
|
name: "generate",
|
|
12681
12842
|
description: "Generate an image with AI and store it in the library (cost-tracked per request via OpenRouter usage). Models mirror the canvas: openai/gpt-5.4-image-2 (default \u2014 photoreal, cleanest text, best for ad/landing reproduction), google/gemini-3-pro-image-preview (Nano Banana Pro), google/gemini-3.5-flash & google/gemini-3.1-flash-image-preview (fast, extreme aspect ratios), recraft/recraft-v4.1-pro-vector (vector/SVG-style with palette control). The result is auto-ingested (describe + embed), so the next `baker images library` query finds it. Pass --reference with image URLs and/or local file paths (Pinterest, stock, brand assets, sandbox files) to ground generation in reality.\n\nExamples:\n baker images generate 'a friendly golden retriever sitting in a bright modern living room' --aspect-ratio 16:9\n baker images generate 'hero shot of a matte black water bottle on marble' --model google/gemini-3-pro-image-preview --image-size 2K\n baker images generate 'lifestyle photo matching this mood' --reference 'https://\u2026/ref1.jpg,https://\u2026/ref2.jpg'\n baker images generate 'put this product on a marble countertop, soft daylight' --reference './src/brand/logos/product.png,./refs/kitchen-mood.jpg'\n baker images generate 'flat geometric mascot, brand palette' --model recraft/recraft-v4.1-pro-vector --rgb-colors '[[10,10,10],[255,80,0]]'"
|
|
@@ -12727,7 +12888,7 @@ var generateCommand = defineCommand94({
|
|
|
12727
12888
|
});
|
|
12728
12889
|
|
|
12729
12890
|
// src/commands/images/get.ts
|
|
12730
|
-
import { defineCommand as
|
|
12891
|
+
import { defineCommand as defineCommand99 } from "citty";
|
|
12731
12892
|
registerSchema({
|
|
12732
12893
|
command: "images.get",
|
|
12733
12894
|
description: "Get a single image by ID",
|
|
@@ -12735,7 +12896,7 @@ registerSchema({
|
|
|
12735
12896
|
id: { type: "string", description: "Image ID", required: true }
|
|
12736
12897
|
}
|
|
12737
12898
|
});
|
|
12738
|
-
var getCommand2 =
|
|
12899
|
+
var getCommand2 = defineCommand99({
|
|
12739
12900
|
meta: { name: "get", description: "Get a single image by ID. Example: baker images get j571abc123" },
|
|
12740
12901
|
args: {
|
|
12741
12902
|
id: { type: "positional", description: "Image ID", required: false },
|
|
@@ -12771,7 +12932,7 @@ var getCommand2 = defineCommand95({
|
|
|
12771
12932
|
});
|
|
12772
12933
|
|
|
12773
12934
|
// src/commands/images/gif.ts
|
|
12774
|
-
import { defineCommand as
|
|
12935
|
+
import { defineCommand as defineCommand100 } from "citty";
|
|
12775
12936
|
registerSchema({
|
|
12776
12937
|
command: "images.gif",
|
|
12777
12938
|
description: "Search Giphy for GIFs / reaction memes (paid social creative).",
|
|
@@ -12803,7 +12964,7 @@ registerSchema({
|
|
|
12803
12964
|
}
|
|
12804
12965
|
}
|
|
12805
12966
|
});
|
|
12806
|
-
var gifCommand =
|
|
12967
|
+
var gifCommand = defineCommand100({
|
|
12807
12968
|
meta: {
|
|
12808
12969
|
name: "gif",
|
|
12809
12970
|
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"
|
|
@@ -12850,7 +13011,7 @@ var gifCommand = defineCommand96({
|
|
|
12850
13011
|
});
|
|
12851
13012
|
|
|
12852
13013
|
// src/commands/images/google.ts
|
|
12853
|
-
import { defineCommand as
|
|
13014
|
+
import { defineCommand as defineCommand101 } from "citty";
|
|
12854
13015
|
registerSchema({
|
|
12855
13016
|
command: "images.google",
|
|
12856
13017
|
description: "Google Images search via the official Custom Search JSON API. Unverified source \u2014 inspect before placing.",
|
|
@@ -12886,7 +13047,7 @@ registerSchema({
|
|
|
12886
13047
|
}
|
|
12887
13048
|
}
|
|
12888
13049
|
});
|
|
12889
|
-
var googleCommand2 =
|
|
13050
|
+
var googleCommand2 = defineCommand101({
|
|
12890
13051
|
meta: {
|
|
12891
13052
|
name: "google",
|
|
12892
13053
|
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"
|
|
@@ -12934,7 +13095,7 @@ var googleCommand2 = defineCommand97({
|
|
|
12934
13095
|
});
|
|
12935
13096
|
|
|
12936
13097
|
// src/commands/images/icon.ts
|
|
12937
|
-
import { defineCommand as
|
|
13098
|
+
import { defineCommand as defineCommand102 } from "citty";
|
|
12938
13099
|
registerSchema({
|
|
12939
13100
|
command: "images.icon",
|
|
12940
13101
|
description: "Icon lookup via Iconify (200+ icon sets, free CDN).",
|
|
@@ -12960,7 +13121,7 @@ registerSchema({
|
|
|
12960
13121
|
}
|
|
12961
13122
|
}
|
|
12962
13123
|
});
|
|
12963
|
-
var iconCommand =
|
|
13124
|
+
var iconCommand = defineCommand102({
|
|
12964
13125
|
meta: {
|
|
12965
13126
|
name: "icon",
|
|
12966
13127
|
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'"
|
|
@@ -13000,7 +13161,7 @@ var iconCommand = defineCommand98({
|
|
|
13000
13161
|
});
|
|
13001
13162
|
|
|
13002
13163
|
// src/commands/images/ingest.ts
|
|
13003
|
-
import { defineCommand as
|
|
13164
|
+
import { defineCommand as defineCommand103 } from "citty";
|
|
13004
13165
|
registerSchema({
|
|
13005
13166
|
command: "images.ingest",
|
|
13006
13167
|
description: "Ingest a remote image URL into the library (full describe + embed).",
|
|
@@ -13012,7 +13173,7 @@ registerSchema({
|
|
|
13012
13173
|
context: { type: "string", description: "Description context hint", required: false }
|
|
13013
13174
|
}
|
|
13014
13175
|
});
|
|
13015
|
-
var ingestCommand =
|
|
13176
|
+
var ingestCommand = defineCommand103({
|
|
13016
13177
|
meta: {
|
|
13017
13178
|
name: "ingest",
|
|
13018
13179
|
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"
|
|
@@ -13054,7 +13215,7 @@ var ingestCommand = defineCommand99({
|
|
|
13054
13215
|
});
|
|
13055
13216
|
|
|
13056
13217
|
// src/commands/images/library.ts
|
|
13057
|
-
import { defineCommand as
|
|
13218
|
+
import { defineCommand as defineCommand104 } from "citty";
|
|
13058
13219
|
registerSchema({
|
|
13059
13220
|
command: "images.library",
|
|
13060
13221
|
description: "Search the company image library. Returns only ready images.",
|
|
@@ -13080,7 +13241,7 @@ registerSchema({
|
|
|
13080
13241
|
}
|
|
13081
13242
|
}
|
|
13082
13243
|
});
|
|
13083
|
-
var libraryCommand =
|
|
13244
|
+
var libraryCommand = defineCommand104({
|
|
13084
13245
|
meta: {
|
|
13085
13246
|
name: "library",
|
|
13086
13247
|
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"
|
|
@@ -13137,7 +13298,7 @@ var libraryCommand = defineCommand100({
|
|
|
13137
13298
|
});
|
|
13138
13299
|
|
|
13139
13300
|
// src/commands/images/logo.ts
|
|
13140
|
-
import { defineCommand as
|
|
13301
|
+
import { defineCommand as defineCommand105 } from "citty";
|
|
13141
13302
|
registerSchema({
|
|
13142
13303
|
command: "images.logo",
|
|
13143
13304
|
description: "Brand logo lookup via Brandfetch CDN (fallback/404). Auto-ingests by default.",
|
|
@@ -13162,7 +13323,7 @@ registerSchema({
|
|
|
13162
13323
|
}
|
|
13163
13324
|
}
|
|
13164
13325
|
});
|
|
13165
|
-
var logoCommand =
|
|
13326
|
+
var logoCommand = defineCommand105({
|
|
13166
13327
|
meta: {
|
|
13167
13328
|
name: "logo",
|
|
13168
13329
|
description: "Brand logo via Brandfetch CDN. Returns up to 5 variants (icon, light/dark logo, light/dark symbol). Auto-ingests the first variant.\n\nExample: baker images logo stripe.com --variant logo"
|
|
@@ -13200,7 +13361,7 @@ var logoCommand = defineCommand101({
|
|
|
13200
13361
|
});
|
|
13201
13362
|
|
|
13202
13363
|
// src/commands/images/normalize.ts
|
|
13203
|
-
import { defineCommand as
|
|
13364
|
+
import { defineCommand as defineCommand106 } from "citty";
|
|
13204
13365
|
|
|
13205
13366
|
// src/lib/image/color-changer.ts
|
|
13206
13367
|
import quantize from "quantize";
|
|
@@ -13932,7 +14093,7 @@ function coerceRawArgs(args) {
|
|
|
13932
14093
|
"dry-run": bool(args["dry-run"])
|
|
13933
14094
|
};
|
|
13934
14095
|
}
|
|
13935
|
-
var normalizeCommand =
|
|
14096
|
+
var normalizeCommand = defineCommand106({
|
|
13936
14097
|
meta: {
|
|
13937
14098
|
name: "normalize",
|
|
13938
14099
|
description: `Normalize logos / images: declarative recolor + bg removal + trim + resize. Operates on local files; writes in-place by default.
|
|
@@ -13987,7 +14148,7 @@ Examples:
|
|
|
13987
14148
|
});
|
|
13988
14149
|
|
|
13989
14150
|
// src/commands/images/pinterest.ts
|
|
13990
|
-
import { defineCommand as
|
|
14151
|
+
import { defineCommand as defineCommand107 } from "citty";
|
|
13991
14152
|
registerSchema({
|
|
13992
14153
|
command: "images.pinterest",
|
|
13993
14154
|
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.",
|
|
@@ -14007,7 +14168,7 @@ registerSchema({
|
|
|
14007
14168
|
}
|
|
14008
14169
|
}
|
|
14009
14170
|
});
|
|
14010
|
-
var pinterestCommand =
|
|
14171
|
+
var pinterestCommand = defineCommand107({
|
|
14011
14172
|
meta: {
|
|
14012
14173
|
name: "pinterest",
|
|
14013
14174
|
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'"
|
|
@@ -14047,7 +14208,7 @@ var pinterestCommand = defineCommand103({
|
|
|
14047
14208
|
});
|
|
14048
14209
|
|
|
14049
14210
|
// src/commands/images/screenshot.ts
|
|
14050
|
-
import { defineCommand as
|
|
14211
|
+
import { defineCommand as defineCommand108 } from "citty";
|
|
14051
14212
|
registerSchema({
|
|
14052
14213
|
command: "images.screenshot",
|
|
14053
14214
|
description: "Capture a website screenshot via ScreenshotOne. Auto-ingests on success.",
|
|
@@ -14063,7 +14224,7 @@ registerSchema({
|
|
|
14063
14224
|
}
|
|
14064
14225
|
}
|
|
14065
14226
|
});
|
|
14066
|
-
var screenshotCommand =
|
|
14227
|
+
var screenshotCommand = defineCommand108({
|
|
14067
14228
|
meta: {
|
|
14068
14229
|
name: "screenshot",
|
|
14069
14230
|
description: "Screenshot a URL via ScreenshotOne. $0.009/capture. Auto-ingests to library.\n\nExample: baker images screenshot https://stripe.com --full-page"
|
|
@@ -14113,7 +14274,7 @@ var screenshotCommand = defineCommand104({
|
|
|
14113
14274
|
});
|
|
14114
14275
|
|
|
14115
14276
|
// src/commands/images/search.ts
|
|
14116
|
-
import { defineCommand as
|
|
14277
|
+
import { defineCommand as defineCommand109 } from "citty";
|
|
14117
14278
|
registerSchema({
|
|
14118
14279
|
command: "images.search",
|
|
14119
14280
|
description: "Search images by text query. Only returns ready images.",
|
|
@@ -14129,7 +14290,7 @@ registerSchema({
|
|
|
14129
14290
|
tags: { type: "string", description: "Comma-separated tags to filter by", required: false }
|
|
14130
14291
|
}
|
|
14131
14292
|
});
|
|
14132
|
-
var searchCommand =
|
|
14293
|
+
var searchCommand = defineCommand109({
|
|
14133
14294
|
meta: {
|
|
14134
14295
|
name: "search",
|
|
14135
14296
|
description: "Semantic search images by text query. Uses hybrid BM25 + vector + reranking. Example: baker images search 'hero banner' --aspect-ratio 16:9 --tags logo"
|
|
@@ -14189,7 +14350,7 @@ var searchCommand = defineCommand105({
|
|
|
14189
14350
|
});
|
|
14190
14351
|
|
|
14191
14352
|
// src/commands/images/sticker.ts
|
|
14192
|
-
import { defineCommand as
|
|
14353
|
+
import { defineCommand as defineCommand110 } from "citty";
|
|
14193
14354
|
registerSchema({
|
|
14194
14355
|
command: "images.sticker",
|
|
14195
14356
|
description: "Search Giphy stickers \u2014 transparent-background overlays for ad creative.",
|
|
@@ -14221,7 +14382,7 @@ registerSchema({
|
|
|
14221
14382
|
}
|
|
14222
14383
|
}
|
|
14223
14384
|
});
|
|
14224
|
-
var stickerCommand =
|
|
14385
|
+
var stickerCommand = defineCommand110({
|
|
14225
14386
|
meta: {
|
|
14226
14387
|
name: "sticker",
|
|
14227
14388
|
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"
|
|
@@ -14268,7 +14429,7 @@ var stickerCommand = defineCommand106({
|
|
|
14268
14429
|
});
|
|
14269
14430
|
|
|
14270
14431
|
// src/commands/images/stock.ts
|
|
14271
|
-
import { defineCommand as
|
|
14432
|
+
import { defineCommand as defineCommand111 } from "citty";
|
|
14272
14433
|
registerSchema({
|
|
14273
14434
|
command: "images.stock",
|
|
14274
14435
|
description: "Stock photo, vector illustration, icon-set, and PSD search via Magnific (Freepik's developer API).",
|
|
@@ -14326,7 +14487,7 @@ registerSchema({
|
|
|
14326
14487
|
}
|
|
14327
14488
|
}
|
|
14328
14489
|
});
|
|
14329
|
-
var stockCommand =
|
|
14490
|
+
var stockCommand = defineCommand111({
|
|
14330
14491
|
meta: {
|
|
14331
14492
|
name: "stock",
|
|
14332
14493
|
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"
|
|
@@ -14381,10 +14542,55 @@ var stockCommand = defineCommand107({
|
|
|
14381
14542
|
}
|
|
14382
14543
|
});
|
|
14383
14544
|
|
|
14545
|
+
// src/lib/tags-command.ts
|
|
14546
|
+
import { defineCommand as defineCommand112 } from "citty";
|
|
14547
|
+
function makeTagsCommand(command, label, endpoint) {
|
|
14548
|
+
registerSchema({
|
|
14549
|
+
command: `${command}.tags`,
|
|
14550
|
+
description: `List the available ${label} tag taxonomy (built-in defaults + this company's custom tags).`,
|
|
14551
|
+
args: {
|
|
14552
|
+
output: { type: "string", description: "Output format: md|json", required: false, default: "md" }
|
|
14553
|
+
}
|
|
14554
|
+
});
|
|
14555
|
+
return defineCommand112({
|
|
14556
|
+
meta: {
|
|
14557
|
+
name: "tags",
|
|
14558
|
+
description: `List the available ${label} tag names (defaults + company custom tags). Use before filtering with --tags. Example: baker ${command} tags`
|
|
14559
|
+
},
|
|
14560
|
+
args: {
|
|
14561
|
+
output: { type: "string", description: "Output format: md|json", required: false, default: "md" }
|
|
14562
|
+
},
|
|
14563
|
+
run: async ({ args }) => {
|
|
14564
|
+
try {
|
|
14565
|
+
const { markdown } = await apiGet(endpoint);
|
|
14566
|
+
if (args.output === "json") {
|
|
14567
|
+
writeJson({ ok: true, data: { markdown } });
|
|
14568
|
+
return;
|
|
14569
|
+
}
|
|
14570
|
+
process.stdout.write(`${markdown.trimEnd()}
|
|
14571
|
+
`);
|
|
14572
|
+
} catch (err) {
|
|
14573
|
+
const code = err instanceof ApiError ? err.code : "INTERNAL_ERROR";
|
|
14574
|
+
const message = err instanceof ApiError ? err.message : "Unexpected error";
|
|
14575
|
+
if (args.output === "json") {
|
|
14576
|
+
writeJson({ ok: false, error: { code, message } });
|
|
14577
|
+
} else {
|
|
14578
|
+
process.stderr.write(`Error: ${message}
|
|
14579
|
+
`);
|
|
14580
|
+
}
|
|
14581
|
+
process.exit(1);
|
|
14582
|
+
}
|
|
14583
|
+
}
|
|
14584
|
+
});
|
|
14585
|
+
}
|
|
14586
|
+
|
|
14587
|
+
// src/commands/images/tags.ts
|
|
14588
|
+
var tagsCommand2 = makeTagsCommand("images", "image", "/api/images/tags");
|
|
14589
|
+
|
|
14384
14590
|
// src/commands/images/upload.ts
|
|
14385
14591
|
import { readFile as readFile9 } from "fs/promises";
|
|
14386
14592
|
import { extname as extname2 } from "path";
|
|
14387
|
-
import { defineCommand as
|
|
14593
|
+
import { defineCommand as defineCommand113 } from "citty";
|
|
14388
14594
|
var MIME_MAP = {
|
|
14389
14595
|
".png": "image/png",
|
|
14390
14596
|
".jpg": "image/jpeg",
|
|
@@ -14439,7 +14645,7 @@ function detectContentType(filePath) {
|
|
|
14439
14645
|
}
|
|
14440
14646
|
return mime;
|
|
14441
14647
|
}
|
|
14442
|
-
var uploadCommand =
|
|
14648
|
+
var uploadCommand = defineCommand113({
|
|
14443
14649
|
meta: {
|
|
14444
14650
|
name: "upload",
|
|
14445
14651
|
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'"
|
|
@@ -14532,7 +14738,7 @@ async function uploadLocal(target, args) {
|
|
|
14532
14738
|
}
|
|
14533
14739
|
|
|
14534
14740
|
// src/commands/images/upscale.ts
|
|
14535
|
-
import { defineCommand as
|
|
14741
|
+
import { defineCommand as defineCommand114 } from "citty";
|
|
14536
14742
|
registerSchema({
|
|
14537
14743
|
command: "images.upscale",
|
|
14538
14744
|
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).",
|
|
@@ -14547,7 +14753,7 @@ registerSchema({
|
|
|
14547
14753
|
}
|
|
14548
14754
|
});
|
|
14549
14755
|
var POLL_INTERVAL_MS3 = 1500;
|
|
14550
|
-
var upscaleCommand =
|
|
14756
|
+
var upscaleCommand = defineCommand114({
|
|
14551
14757
|
meta: {
|
|
14552
14758
|
name: "upscale",
|
|
14553
14759
|
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"
|
|
@@ -14602,7 +14808,7 @@ var upscaleCommand = defineCommand109({
|
|
|
14602
14808
|
});
|
|
14603
14809
|
|
|
14604
14810
|
// src/commands/images/use.ts
|
|
14605
|
-
import { defineCommand as
|
|
14811
|
+
import { defineCommand as defineCommand115 } from "citty";
|
|
14606
14812
|
registerSchema({
|
|
14607
14813
|
command: "images.use",
|
|
14608
14814
|
description: "Ingest a URL and wait for the library record to be ready.",
|
|
@@ -14618,7 +14824,7 @@ registerSchema({
|
|
|
14618
14824
|
}
|
|
14619
14825
|
});
|
|
14620
14826
|
var POLL_INTERVAL_MS4 = 1500;
|
|
14621
|
-
var useCommand =
|
|
14827
|
+
var useCommand = defineCommand115({
|
|
14622
14828
|
meta: {
|
|
14623
14829
|
name: "use",
|
|
14624
14830
|
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"
|
|
@@ -14664,7 +14870,7 @@ var useCommand = defineCommand110({
|
|
|
14664
14870
|
});
|
|
14665
14871
|
|
|
14666
14872
|
// src/commands/images/index.ts
|
|
14667
|
-
var imagesCommand =
|
|
14873
|
+
var imagesCommand = defineCommand116({
|
|
14668
14874
|
meta: {
|
|
14669
14875
|
name: "images",
|
|
14670
14876
|
description: `Find, source, and normalize images. Subcommands route by provider so cost + license are explicit.
|
|
@@ -14700,6 +14906,9 @@ Local transforms (operate on files in the sandbox, before upload):
|
|
|
14700
14906
|
Coordinate-based rectangular extract
|
|
14701
14907
|
baker images dimensions <file-or-url> Width / height / aspect / format without decoding the full image
|
|
14702
14908
|
|
|
14909
|
+
Taxonomy:
|
|
14910
|
+
baker images tags List available image tag names (defaults + company custom tags)
|
|
14911
|
+
|
|
14703
14912
|
Paid transforms (run on the Convex backend, cost-tracked):
|
|
14704
14913
|
baker images upscale <imageId> Real-ESRGAN super-resolution ($0.05/image, waits for completion)`
|
|
14705
14914
|
},
|
|
@@ -14725,15 +14934,16 @@ Paid transforms (run on the Convex backend, cost-tracked):
|
|
|
14725
14934
|
normalize: normalizeCommand,
|
|
14726
14935
|
crop: cropCommand,
|
|
14727
14936
|
dimensions: dimensionsCommand,
|
|
14728
|
-
upscale: upscaleCommand
|
|
14937
|
+
upscale: upscaleCommand,
|
|
14938
|
+
tags: tagsCommand2
|
|
14729
14939
|
}
|
|
14730
14940
|
});
|
|
14731
14941
|
|
|
14732
14942
|
// src/commands/research/index.ts
|
|
14733
|
-
import { defineCommand as
|
|
14943
|
+
import { defineCommand as defineCommand127 } from "citty";
|
|
14734
14944
|
|
|
14735
14945
|
// src/commands/research/advertisers.ts
|
|
14736
|
-
import { defineCommand as
|
|
14946
|
+
import { defineCommand as defineCommand117 } from "citty";
|
|
14737
14947
|
|
|
14738
14948
|
// src/commands/research/output.ts
|
|
14739
14949
|
var RESEARCH_DATA_NOTE = "Estimates based on third-party SERP data \u2014 not exact figures. Use for directional insights, not precise measurement.";
|
|
@@ -14846,7 +15056,7 @@ var FIELDS3 = {
|
|
|
14846
15056
|
etv: "Estimated traffic value (USD)",
|
|
14847
15057
|
visibility: "SERP visibility score (0-1)"
|
|
14848
15058
|
};
|
|
14849
|
-
var advertisersCommand =
|
|
15059
|
+
var advertisersCommand = defineCommand117({
|
|
14850
15060
|
meta: {
|
|
14851
15061
|
name: "advertisers",
|
|
14852
15062
|
description: `Find domains competing for a keyword in Google SERPs.
|
|
@@ -14893,7 +15103,7 @@ Examples:
|
|
|
14893
15103
|
});
|
|
14894
15104
|
|
|
14895
15105
|
// src/commands/research/autocomplete.ts
|
|
14896
|
-
import { defineCommand as
|
|
15106
|
+
import { defineCommand as defineCommand118 } from "citty";
|
|
14897
15107
|
registerSchema({
|
|
14898
15108
|
command: "research.autocomplete",
|
|
14899
15109
|
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).",
|
|
@@ -14916,7 +15126,7 @@ registerSchema({
|
|
|
14916
15126
|
var FIELDS4 = {
|
|
14917
15127
|
suggestion: "Autocomplete suggestion from Google"
|
|
14918
15128
|
};
|
|
14919
|
-
var autocompleteCommand =
|
|
15129
|
+
var autocompleteCommand = defineCommand118({
|
|
14920
15130
|
meta: {
|
|
14921
15131
|
name: "autocomplete",
|
|
14922
15132
|
description: `Get Google Autocomplete suggestions for keyword expansion.
|
|
@@ -14962,7 +15172,7 @@ Examples:
|
|
|
14962
15172
|
});
|
|
14963
15173
|
|
|
14964
15174
|
// src/commands/research/countries.ts
|
|
14965
|
-
import { defineCommand as
|
|
15175
|
+
import { defineCommand as defineCommand119 } from "citty";
|
|
14966
15176
|
registerSchema({
|
|
14967
15177
|
command: "research.countries",
|
|
14968
15178
|
description: "List all supported country codes for --location flag in research commands.",
|
|
@@ -15019,7 +15229,7 @@ var FIELDS5 = {
|
|
|
15019
15229
|
code: "Country code to pass as --location",
|
|
15020
15230
|
name: "Country name"
|
|
15021
15231
|
};
|
|
15022
|
-
var countriesCommand =
|
|
15232
|
+
var countriesCommand = defineCommand119({
|
|
15023
15233
|
meta: {
|
|
15024
15234
|
name: "countries",
|
|
15025
15235
|
description: "List all supported country codes for --location flag."
|
|
@@ -15030,7 +15240,7 @@ var countriesCommand = defineCommand114({
|
|
|
15030
15240
|
});
|
|
15031
15241
|
|
|
15032
15242
|
// src/commands/research/intent.ts
|
|
15033
|
-
import { defineCommand as
|
|
15243
|
+
import { defineCommand as defineCommand120 } from "citty";
|
|
15034
15244
|
registerSchema({
|
|
15035
15245
|
command: "research.intent",
|
|
15036
15246
|
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.",
|
|
@@ -15053,7 +15263,7 @@ var FIELDS6 = {
|
|
|
15053
15263
|
intent: "Primary Google Search intent: informational, navigational, commercial, transactional",
|
|
15054
15264
|
probability: "Confidence score 0.0-1.0"
|
|
15055
15265
|
};
|
|
15056
|
-
var intentCommand =
|
|
15266
|
+
var intentCommand = defineCommand120({
|
|
15057
15267
|
meta: {
|
|
15058
15268
|
name: "intent",
|
|
15059
15269
|
description: `Classify Google Search intent for keywords. Returns intent type and confidence.
|
|
@@ -15101,7 +15311,7 @@ Examples:
|
|
|
15101
15311
|
});
|
|
15102
15312
|
|
|
15103
15313
|
// src/commands/research/keyword-gap.ts
|
|
15104
|
-
import { defineCommand as
|
|
15314
|
+
import { defineCommand as defineCommand121 } from "citty";
|
|
15105
15315
|
registerSchema({
|
|
15106
15316
|
command: "research.keyword-gap",
|
|
15107
15317
|
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.",
|
|
@@ -15130,7 +15340,7 @@ var FIELDS7 = {
|
|
|
15130
15340
|
cpc: "Cost per click USD",
|
|
15131
15341
|
their_position: "Competitor's ranking position"
|
|
15132
15342
|
};
|
|
15133
|
-
var keywordGapCommand =
|
|
15343
|
+
var keywordGapCommand = defineCommand121({
|
|
15134
15344
|
meta: {
|
|
15135
15345
|
name: "keyword-gap",
|
|
15136
15346
|
description: `Find keywords a competitor has that you don't. Supports pagination via --offset.
|
|
@@ -15204,7 +15414,7 @@ Examples:
|
|
|
15204
15414
|
});
|
|
15205
15415
|
|
|
15206
15416
|
// src/commands/research/keywords-for-site.ts
|
|
15207
|
-
import { defineCommand as
|
|
15417
|
+
import { defineCommand as defineCommand122 } from "citty";
|
|
15208
15418
|
registerSchema({
|
|
15209
15419
|
command: "research.keywords-for-site",
|
|
15210
15420
|
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.",
|
|
@@ -15237,7 +15447,7 @@ var FIELDS8 = {
|
|
|
15237
15447
|
competition: "LOW, MEDIUM, or HIGH",
|
|
15238
15448
|
competition_index: "Competition score 0-100"
|
|
15239
15449
|
};
|
|
15240
|
-
var keywordsForSiteCommand =
|
|
15450
|
+
var keywordsForSiteCommand = defineCommand122({
|
|
15241
15451
|
meta: {
|
|
15242
15452
|
name: "keywords-for-site",
|
|
15243
15453
|
description: `Get keywords a competitor targets in Google. Use --type to filter paid/organic.
|
|
@@ -15290,7 +15500,7 @@ Examples:
|
|
|
15290
15500
|
});
|
|
15291
15501
|
|
|
15292
15502
|
// src/commands/research/languages.ts
|
|
15293
|
-
import { defineCommand as
|
|
15503
|
+
import { defineCommand as defineCommand123 } from "citty";
|
|
15294
15504
|
registerSchema({
|
|
15295
15505
|
command: "research.languages",
|
|
15296
15506
|
description: "List all supported language codes for --language flag in research commands.",
|
|
@@ -15320,7 +15530,7 @@ var FIELDS9 = {
|
|
|
15320
15530
|
code: "Language code to pass as --language",
|
|
15321
15531
|
name: "Language name (also accepted by --language)"
|
|
15322
15532
|
};
|
|
15323
|
-
var languagesCommand2 =
|
|
15533
|
+
var languagesCommand2 = defineCommand123({
|
|
15324
15534
|
meta: {
|
|
15325
15535
|
name: "languages",
|
|
15326
15536
|
description: "List all supported language codes for --language flag."
|
|
@@ -15331,7 +15541,7 @@ var languagesCommand2 = defineCommand118({
|
|
|
15331
15541
|
});
|
|
15332
15542
|
|
|
15333
15543
|
// src/commands/research/lighthouse.ts
|
|
15334
|
-
import { defineCommand as
|
|
15544
|
+
import { defineCommand as defineCommand124 } from "citty";
|
|
15335
15545
|
registerSchema({
|
|
15336
15546
|
command: "research.lighthouse",
|
|
15337
15547
|
description: "Landing page performance audit. Returns metrics that affect Google Ads Quality Score and CPC.",
|
|
@@ -15350,7 +15560,7 @@ var FIELDS10 = {
|
|
|
15350
15560
|
speed_index_ms: "Speed Index in ms (good: < 3400)",
|
|
15351
15561
|
interactive_ms: "Time to Interactive in ms (good: < 3800)"
|
|
15352
15562
|
};
|
|
15353
|
-
var lighthouseCommand =
|
|
15563
|
+
var lighthouseCommand = defineCommand124({
|
|
15354
15564
|
meta: {
|
|
15355
15565
|
name: "lighthouse",
|
|
15356
15566
|
description: `Landing page performance audit. Metrics affecting Google Ads Quality Score.
|
|
@@ -15388,7 +15598,7 @@ Examples:
|
|
|
15388
15598
|
});
|
|
15389
15599
|
|
|
15390
15600
|
// src/commands/research/relevant-pages.ts
|
|
15391
|
-
import { defineCommand as
|
|
15601
|
+
import { defineCommand as defineCommand125 } from "citty";
|
|
15392
15602
|
registerSchema({
|
|
15393
15603
|
command: "research.relevant-pages",
|
|
15394
15604
|
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).",
|
|
@@ -15414,7 +15624,7 @@ var FIELDS11 = {
|
|
|
15414
15624
|
keywords: "Total organic keywords the page ranks for",
|
|
15415
15625
|
top_10: "Keywords in positions 1-10"
|
|
15416
15626
|
};
|
|
15417
|
-
var relevantPagesCommand =
|
|
15627
|
+
var relevantPagesCommand = defineCommand125({
|
|
15418
15628
|
meta: {
|
|
15419
15629
|
name: "relevant-pages",
|
|
15420
15630
|
description: `Get the top pages of a competitor domain with traffic data.
|
|
@@ -15460,7 +15670,7 @@ Examples:
|
|
|
15460
15670
|
});
|
|
15461
15671
|
|
|
15462
15672
|
// src/commands/research/web.ts
|
|
15463
|
-
import { defineCommand as
|
|
15673
|
+
import { defineCommand as defineCommand126 } from "citty";
|
|
15464
15674
|
registerSchema({
|
|
15465
15675
|
command: "research.web",
|
|
15466
15676
|
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).",
|
|
@@ -15511,7 +15721,7 @@ async function runDeepResearch(question) {
|
|
|
15511
15721
|
}
|
|
15512
15722
|
throw new Error("Deep research timed out");
|
|
15513
15723
|
}
|
|
15514
|
-
var webCommand =
|
|
15724
|
+
var webCommand = defineCommand126({
|
|
15515
15725
|
meta: {
|
|
15516
15726
|
name: "web",
|
|
15517
15727
|
description: `Search the web with AI to answer any open-ended marketing question. Uses live internet data via Google Search.
|
|
@@ -15571,7 +15781,7 @@ Examples:
|
|
|
15571
15781
|
});
|
|
15572
15782
|
|
|
15573
15783
|
// src/commands/research/index.ts
|
|
15574
|
-
var researchCommand =
|
|
15784
|
+
var researchCommand = defineCommand127({
|
|
15575
15785
|
meta: {
|
|
15576
15786
|
name: "research",
|
|
15577
15787
|
description: `Competitive intelligence and AI-powered research commands.
|
|
@@ -15611,10 +15821,10 @@ Examples:
|
|
|
15611
15821
|
});
|
|
15612
15822
|
|
|
15613
15823
|
// src/commands/scheduled-actions/index.ts
|
|
15614
|
-
import { defineCommand as
|
|
15824
|
+
import { defineCommand as defineCommand134 } from "citty";
|
|
15615
15825
|
|
|
15616
15826
|
// src/commands/scheduled-actions/create.ts
|
|
15617
|
-
import { defineCommand as
|
|
15827
|
+
import { defineCommand as defineCommand128 } from "citty";
|
|
15618
15828
|
|
|
15619
15829
|
// src/commands/scheduled-actions/shared.ts
|
|
15620
15830
|
var TEMP_SCHEDULED_ACTION_PREFIX = "temp_sched_";
|
|
@@ -15719,7 +15929,7 @@ registerSchema({
|
|
|
15719
15929
|
prompt: { type: "string", description: "Additional prompt instructions for the spawned agent", required: false }
|
|
15720
15930
|
}
|
|
15721
15931
|
});
|
|
15722
|
-
var createCommand2 =
|
|
15932
|
+
var createCommand2 = defineCommand128({
|
|
15723
15933
|
meta: {
|
|
15724
15934
|
name: "create",
|
|
15725
15935
|
description: 'Stage a scheduled action. Example: baker scheduled-actions create --name "Weekly report" --description "..." --cron "0 9 * * MON"'
|
|
@@ -15767,7 +15977,7 @@ var createCommand2 = defineCommand123({
|
|
|
15767
15977
|
});
|
|
15768
15978
|
|
|
15769
15979
|
// src/commands/scheduled-actions/delete.ts
|
|
15770
|
-
import { defineCommand as
|
|
15980
|
+
import { defineCommand as defineCommand129 } from "citty";
|
|
15771
15981
|
registerSchema({
|
|
15772
15982
|
command: "scheduled-actions.delete",
|
|
15773
15983
|
description: "Stage deletion of a published scheduled action or cancellation of a temp_sched_* draft creation.",
|
|
@@ -15775,7 +15985,7 @@ registerSchema({
|
|
|
15775
15985
|
id: { type: "string", description: "Published scheduled action ID or temp_sched_* draft ID", required: true }
|
|
15776
15986
|
}
|
|
15777
15987
|
});
|
|
15778
|
-
var deleteCommand2 =
|
|
15988
|
+
var deleteCommand2 = defineCommand129({
|
|
15779
15989
|
meta: {
|
|
15780
15990
|
name: "delete",
|
|
15781
15991
|
description: "Stage scheduled action deletion. Example: baker scheduled-actions delete <id-or-temp_sched_id>"
|
|
@@ -15804,7 +16014,7 @@ var deleteCommand2 = defineCommand124({
|
|
|
15804
16014
|
});
|
|
15805
16015
|
|
|
15806
16016
|
// src/commands/scheduled-actions/get.ts
|
|
15807
|
-
import { defineCommand as
|
|
16017
|
+
import { defineCommand as defineCommand130 } from "citty";
|
|
15808
16018
|
registerSchema({
|
|
15809
16019
|
command: "scheduled-actions.get",
|
|
15810
16020
|
description: "Get a published scheduled action or a temp_sched_* draft-created scheduled action.",
|
|
@@ -15812,7 +16022,7 @@ registerSchema({
|
|
|
15812
16022
|
id: { type: "string", description: "Published scheduled action ID or temp_sched_* draft ID", required: true }
|
|
15813
16023
|
}
|
|
15814
16024
|
});
|
|
15815
|
-
var getCommand3 =
|
|
16025
|
+
var getCommand3 = defineCommand130({
|
|
15816
16026
|
meta: {
|
|
15817
16027
|
name: "get",
|
|
15818
16028
|
description: "Get a scheduled action. Example: baker scheduled-actions get <id-or-temp_sched_id>"
|
|
@@ -15849,13 +16059,13 @@ var getCommand3 = defineCommand125({
|
|
|
15849
16059
|
});
|
|
15850
16060
|
|
|
15851
16061
|
// src/commands/scheduled-actions/list.ts
|
|
15852
|
-
import { defineCommand as
|
|
16062
|
+
import { defineCommand as defineCommand131 } from "citty";
|
|
15853
16063
|
registerSchema({
|
|
15854
16064
|
command: "scheduled-actions.list",
|
|
15855
16065
|
description: "List published scheduled actions. Includes draft state when BAKER_CHAT_ID is set.",
|
|
15856
16066
|
args: {}
|
|
15857
16067
|
});
|
|
15858
|
-
var listCommand3 =
|
|
16068
|
+
var listCommand3 = defineCommand131({
|
|
15859
16069
|
meta: {
|
|
15860
16070
|
name: "list",
|
|
15861
16071
|
description: "List scheduled actions. Includes staged draft ops when BAKER_CHAT_ID is set."
|
|
@@ -15876,7 +16086,7 @@ var listCommand3 = defineCommand126({
|
|
|
15876
16086
|
});
|
|
15877
16087
|
|
|
15878
16088
|
// src/commands/scheduled-actions/trigger.ts
|
|
15879
|
-
import { defineCommand as
|
|
16089
|
+
import { defineCommand as defineCommand132 } from "citty";
|
|
15880
16090
|
registerSchema({
|
|
15881
16091
|
command: "scheduled-actions.trigger",
|
|
15882
16092
|
description: "Immediately trigger a published scheduled action. Does not require BAKER_CHAT_ID and rejects temp_sched_* IDs.",
|
|
@@ -15884,7 +16094,7 @@ registerSchema({
|
|
|
15884
16094
|
id: { type: "string", description: "Published scheduled action ID", required: true }
|
|
15885
16095
|
}
|
|
15886
16096
|
});
|
|
15887
|
-
var triggerCommand =
|
|
16097
|
+
var triggerCommand = defineCommand132({
|
|
15888
16098
|
meta: {
|
|
15889
16099
|
name: "trigger",
|
|
15890
16100
|
description: "Immediately trigger a published scheduled action. Example: baker scheduled-actions trigger <id>"
|
|
@@ -15921,7 +16131,7 @@ var triggerCommand = defineCommand127({
|
|
|
15921
16131
|
});
|
|
15922
16132
|
|
|
15923
16133
|
// src/commands/scheduled-actions/update.ts
|
|
15924
|
-
import { defineCommand as
|
|
16134
|
+
import { defineCommand as defineCommand133 } from "citty";
|
|
15925
16135
|
registerSchema({
|
|
15926
16136
|
command: "scheduled-actions.update",
|
|
15927
16137
|
description: "Stage an update to a published scheduled action or temp_sched_* draft-created scheduled action.",
|
|
@@ -15946,7 +16156,7 @@ registerSchema({
|
|
|
15946
16156
|
prompt: { type: "string", description: "Replacement additional spawned-agent instructions", required: false }
|
|
15947
16157
|
}
|
|
15948
16158
|
});
|
|
15949
|
-
var updateCommand2 =
|
|
16159
|
+
var updateCommand2 = defineCommand133({
|
|
15950
16160
|
meta: {
|
|
15951
16161
|
name: "update",
|
|
15952
16162
|
description: "Stage a scheduled action update. Example: baker scheduled-actions update <id> --enabled false"
|
|
@@ -16016,7 +16226,7 @@ var updateCommand2 = defineCommand128({
|
|
|
16016
16226
|
});
|
|
16017
16227
|
|
|
16018
16228
|
// src/commands/scheduled-actions/index.ts
|
|
16019
|
-
var scheduledActionsCommand =
|
|
16229
|
+
var scheduledActionsCommand = defineCommand134({
|
|
16020
16230
|
meta: {
|
|
16021
16231
|
name: "scheduled-actions",
|
|
16022
16232
|
description: `Manage Scheduled Actions. Subcommands: list, get, create, update, delete, trigger.
|
|
@@ -16042,8 +16252,8 @@ Examples:
|
|
|
16042
16252
|
});
|
|
16043
16253
|
|
|
16044
16254
|
// src/commands/schema.ts
|
|
16045
|
-
import { defineCommand as
|
|
16046
|
-
var schemaCommand =
|
|
16255
|
+
import { defineCommand as defineCommand135 } from "citty";
|
|
16256
|
+
var schemaCommand = defineCommand135({
|
|
16047
16257
|
meta: {
|
|
16048
16258
|
name: "schema",
|
|
16049
16259
|
description: "Inspect command argument schemas (for AI agent introspection). Lists all commands if no argument given. Example: baker schema images.search"
|
|
@@ -16079,10 +16289,10 @@ var schemaCommand = defineCommand130({
|
|
|
16079
16289
|
});
|
|
16080
16290
|
|
|
16081
16291
|
// src/commands/testimonials/index.ts
|
|
16082
|
-
import { defineCommand as
|
|
16292
|
+
import { defineCommand as defineCommand139 } from "citty";
|
|
16083
16293
|
|
|
16084
16294
|
// src/commands/testimonials/get.ts
|
|
16085
|
-
import { defineCommand as
|
|
16295
|
+
import { defineCommand as defineCommand136 } from "citty";
|
|
16086
16296
|
registerSchema({
|
|
16087
16297
|
command: "testimonials.get",
|
|
16088
16298
|
description: "Get a single testimonial by ID",
|
|
@@ -16090,7 +16300,7 @@ registerSchema({
|
|
|
16090
16300
|
id: { type: "string", description: "Testimonial ID", required: true }
|
|
16091
16301
|
}
|
|
16092
16302
|
});
|
|
16093
|
-
var getCommand4 =
|
|
16303
|
+
var getCommand4 = defineCommand136({
|
|
16094
16304
|
meta: { name: "get", description: "Get a single testimonial by ID. Example: baker testimonials get j571abc123" },
|
|
16095
16305
|
args: {
|
|
16096
16306
|
id: { type: "positional", description: "Testimonial ID", required: false },
|
|
@@ -16127,7 +16337,7 @@ var getCommand4 = defineCommand131({
|
|
|
16127
16337
|
});
|
|
16128
16338
|
|
|
16129
16339
|
// src/commands/testimonials/list.ts
|
|
16130
|
-
import { defineCommand as
|
|
16340
|
+
import { defineCommand as defineCommand137 } from "citty";
|
|
16131
16341
|
registerSchema({
|
|
16132
16342
|
command: "testimonials.list",
|
|
16133
16343
|
description: "List testimonials with optional filters.",
|
|
@@ -16157,7 +16367,7 @@ registerSchema({
|
|
|
16157
16367
|
limit: { type: "number", description: "Max results (default 50)", required: false, default: 50 }
|
|
16158
16368
|
}
|
|
16159
16369
|
});
|
|
16160
|
-
var listCommand4 =
|
|
16370
|
+
var listCommand4 = defineCommand137({
|
|
16161
16371
|
meta: {
|
|
16162
16372
|
name: "list",
|
|
16163
16373
|
description: "List testimonials with optional filters. Example: baker testimonials list --source google --sentiment positive"
|
|
@@ -16206,7 +16416,7 @@ var listCommand4 = defineCommand132({
|
|
|
16206
16416
|
});
|
|
16207
16417
|
|
|
16208
16418
|
// src/commands/testimonials/search.ts
|
|
16209
|
-
import { defineCommand as
|
|
16419
|
+
import { defineCommand as defineCommand138 } from "citty";
|
|
16210
16420
|
registerSchema({
|
|
16211
16421
|
command: "testimonials.search",
|
|
16212
16422
|
description: "Search testimonials by text query. Uses hybrid BM25 + vector + reranking.",
|
|
@@ -16237,7 +16447,7 @@ registerSchema({
|
|
|
16237
16447
|
tags: { type: "string", description: "Comma-separated tags to filter by", required: false }
|
|
16238
16448
|
}
|
|
16239
16449
|
});
|
|
16240
|
-
var searchCommand2 =
|
|
16450
|
+
var searchCommand2 = defineCommand138({
|
|
16241
16451
|
meta: {
|
|
16242
16452
|
name: "search",
|
|
16243
16453
|
description: "Semantic search testimonials by text query. Uses hybrid BM25 + vector + reranking. Example: baker testimonials search 'great service' --rating-min 4"
|
|
@@ -16307,30 +16517,35 @@ var searchCommand2 = defineCommand133({
|
|
|
16307
16517
|
}
|
|
16308
16518
|
});
|
|
16309
16519
|
|
|
16520
|
+
// src/commands/testimonials/tags.ts
|
|
16521
|
+
var tagsCommand3 = makeTagsCommand("testimonials", "testimonial", "/api/testimonials/tags");
|
|
16522
|
+
|
|
16310
16523
|
// src/commands/testimonials/index.ts
|
|
16311
|
-
var testimonialsCommand =
|
|
16524
|
+
var testimonialsCommand = defineCommand139({
|
|
16312
16525
|
meta: {
|
|
16313
16526
|
name: "testimonials",
|
|
16314
|
-
description: `Find and browse testimonials in Baker. Subcommands: search, get, list.
|
|
16527
|
+
description: `Find and browse testimonials in Baker. Subcommands: search, get, list, tags.
|
|
16315
16528
|
|
|
16316
16529
|
Examples:
|
|
16317
16530
|
baker testimonials search "great customer service" --limit 5
|
|
16318
16531
|
baker testimonials search "value for money" --rating-min 4
|
|
16319
16532
|
baker testimonials get <testimonial-id>
|
|
16320
|
-
baker testimonials list --source google --sentiment positive
|
|
16533
|
+
baker testimonials list --source google --sentiment positive
|
|
16534
|
+
baker testimonials tags`
|
|
16321
16535
|
},
|
|
16322
16536
|
subCommands: {
|
|
16323
16537
|
get: getCommand4,
|
|
16324
16538
|
search: searchCommand2,
|
|
16325
|
-
list: listCommand4
|
|
16539
|
+
list: listCommand4,
|
|
16540
|
+
tags: tagsCommand3
|
|
16326
16541
|
}
|
|
16327
16542
|
});
|
|
16328
16543
|
|
|
16329
16544
|
// src/commands/videos/index.ts
|
|
16330
|
-
import { defineCommand as
|
|
16545
|
+
import { defineCommand as defineCommand144 } from "citty";
|
|
16331
16546
|
|
|
16332
16547
|
// src/commands/videos/delete.ts
|
|
16333
|
-
import { defineCommand as
|
|
16548
|
+
import { defineCommand as defineCommand140 } from "citty";
|
|
16334
16549
|
registerSchema({
|
|
16335
16550
|
command: "videos.delete",
|
|
16336
16551
|
description: "Delete a video by ID",
|
|
@@ -16344,7 +16559,7 @@ registerSchema({
|
|
|
16344
16559
|
}
|
|
16345
16560
|
}
|
|
16346
16561
|
});
|
|
16347
|
-
var deleteCommand3 =
|
|
16562
|
+
var deleteCommand3 = defineCommand140({
|
|
16348
16563
|
meta: {
|
|
16349
16564
|
name: "delete",
|
|
16350
16565
|
description: "Delete a video by ID. Use --dry-run to preview. Example: baker videos delete j571abc123 --dry-run"
|
|
@@ -16385,7 +16600,7 @@ var deleteCommand3 = defineCommand135({
|
|
|
16385
16600
|
});
|
|
16386
16601
|
|
|
16387
16602
|
// src/commands/videos/get.ts
|
|
16388
|
-
import { defineCommand as
|
|
16603
|
+
import { defineCommand as defineCommand141 } from "citty";
|
|
16389
16604
|
registerSchema({
|
|
16390
16605
|
command: "videos.get",
|
|
16391
16606
|
description: "Get a single video by ID",
|
|
@@ -16393,7 +16608,7 @@ registerSchema({
|
|
|
16393
16608
|
id: { type: "string", description: "Video ID", required: true }
|
|
16394
16609
|
}
|
|
16395
16610
|
});
|
|
16396
|
-
var getCommand5 =
|
|
16611
|
+
var getCommand5 = defineCommand141({
|
|
16397
16612
|
meta: { name: "get", description: "Get a single video by ID. Example: baker videos get j571abc123" },
|
|
16398
16613
|
args: {
|
|
16399
16614
|
id: { type: "positional", description: "Video ID", required: false },
|
|
@@ -16430,7 +16645,7 @@ var getCommand5 = defineCommand136({
|
|
|
16430
16645
|
});
|
|
16431
16646
|
|
|
16432
16647
|
// src/commands/videos/search.ts
|
|
16433
|
-
import { defineCommand as
|
|
16648
|
+
import { defineCommand as defineCommand142 } from "citty";
|
|
16434
16649
|
registerSchema({
|
|
16435
16650
|
command: "videos.search",
|
|
16436
16651
|
description: "Search videos by text query. Only returns ready videos.",
|
|
@@ -16440,7 +16655,7 @@ registerSchema({
|
|
|
16440
16655
|
tags: { type: "string", description: "Comma-separated tags to filter by", required: false }
|
|
16441
16656
|
}
|
|
16442
16657
|
});
|
|
16443
|
-
var searchCommand3 =
|
|
16658
|
+
var searchCommand3 = defineCommand142({
|
|
16444
16659
|
meta: {
|
|
16445
16660
|
name: "search",
|
|
16446
16661
|
description: "Semantic search videos by text query. Uses hybrid BM25 + vector + reranking. Example: baker videos search 'product demo' --tags tutorial"
|
|
@@ -16486,10 +16701,13 @@ var searchCommand3 = defineCommand137({
|
|
|
16486
16701
|
}
|
|
16487
16702
|
});
|
|
16488
16703
|
|
|
16704
|
+
// src/commands/videos/tags.ts
|
|
16705
|
+
var tagsCommand4 = makeTagsCommand("videos", "video", "/api/videos/tags");
|
|
16706
|
+
|
|
16489
16707
|
// src/commands/videos/upload.ts
|
|
16490
16708
|
import { readFile as readFile10, stat as stat3 } from "fs/promises";
|
|
16491
16709
|
import { extname as extname3 } from "path";
|
|
16492
|
-
import { defineCommand as
|
|
16710
|
+
import { defineCommand as defineCommand143 } from "citty";
|
|
16493
16711
|
var MIME_MAP2 = {
|
|
16494
16712
|
".mp4": "video/mp4",
|
|
16495
16713
|
".mov": "video/quicktime",
|
|
@@ -16523,7 +16741,7 @@ function detectContentType2(filePath) {
|
|
|
16523
16741
|
}
|
|
16524
16742
|
return mime;
|
|
16525
16743
|
}
|
|
16526
|
-
var uploadCommand2 =
|
|
16744
|
+
var uploadCommand2 = defineCommand143({
|
|
16527
16745
|
meta: {
|
|
16528
16746
|
name: "upload",
|
|
16529
16747
|
description: "Upload a video file to Baker via Mux direct upload. Auto-detects content type. Example: baker videos upload ./demo.mp4"
|
|
@@ -16577,31 +16795,33 @@ var uploadCommand2 = defineCommand138({
|
|
|
16577
16795
|
});
|
|
16578
16796
|
|
|
16579
16797
|
// src/commands/videos/index.ts
|
|
16580
|
-
var videosCommand =
|
|
16798
|
+
var videosCommand = defineCommand144({
|
|
16581
16799
|
meta: {
|
|
16582
16800
|
name: "videos",
|
|
16583
|
-
description: `Find and manage videos in Baker. Subcommands: search, get, upload, delete.
|
|
16801
|
+
description: `Find and manage videos in Baker. Subcommands: search, get, upload, delete, tags.
|
|
16584
16802
|
|
|
16585
16803
|
Examples:
|
|
16586
16804
|
baker videos search "product demo" --limit 5
|
|
16587
16805
|
baker videos search "tutorial" --tags explainer
|
|
16588
16806
|
baker videos get <video-id>
|
|
16589
16807
|
baker videos upload ./demo.mp4
|
|
16590
|
-
baker videos delete <video-id> --dry-run
|
|
16808
|
+
baker videos delete <video-id> --dry-run
|
|
16809
|
+
baker videos tags`
|
|
16591
16810
|
},
|
|
16592
16811
|
subCommands: {
|
|
16593
16812
|
get: getCommand5,
|
|
16594
16813
|
search: searchCommand3,
|
|
16595
16814
|
upload: uploadCommand2,
|
|
16596
|
-
delete: deleteCommand3
|
|
16815
|
+
delete: deleteCommand3,
|
|
16816
|
+
tags: tagsCommand4
|
|
16597
16817
|
}
|
|
16598
16818
|
});
|
|
16599
16819
|
|
|
16600
16820
|
// src/commands/winning-ads/index.ts
|
|
16601
|
-
import { defineCommand as
|
|
16821
|
+
import { defineCommand as defineCommand147 } from "citty";
|
|
16602
16822
|
|
|
16603
16823
|
// src/commands/winning-ads/advertisers.ts
|
|
16604
|
-
import { defineCommand as
|
|
16824
|
+
import { defineCommand as defineCommand145 } from "citty";
|
|
16605
16825
|
registerSchema({
|
|
16606
16826
|
command: "winning-ads.advertisers",
|
|
16607
16827
|
description: "Resolve a brand name to advertiser_id(s) in the ad-dna corpus \u2014 to find your OWN advertiser (to --exclude-advertiser) or a competitor (to --advertiser-id).",
|
|
@@ -16614,7 +16834,7 @@ registerSchema({
|
|
|
16614
16834
|
function identity(record) {
|
|
16615
16835
|
return record;
|
|
16616
16836
|
}
|
|
16617
|
-
var advertisersCommand2 =
|
|
16837
|
+
var advertisersCommand2 = defineCommand145({
|
|
16618
16838
|
meta: {
|
|
16619
16839
|
name: "advertisers",
|
|
16620
16840
|
description: 'Resolve a brand name to advertiser_id(s). Use it to find your own advertiser for --exclude-advertiser, or a competitor for --advertiser-id. Example: baker winning-ads advertisers "Deel" --output md'
|
|
@@ -16665,7 +16885,7 @@ var advertisersCommand2 = defineCommand140({
|
|
|
16665
16885
|
});
|
|
16666
16886
|
|
|
16667
16887
|
// src/commands/winning-ads/search.ts
|
|
16668
|
-
import { defineCommand as
|
|
16888
|
+
import { defineCommand as defineCommand146 } from "citty";
|
|
16669
16889
|
registerSchema({
|
|
16670
16890
|
command: "winning-ads.search",
|
|
16671
16891
|
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.",
|
|
@@ -16773,7 +16993,7 @@ function buildSearchBody(args) {
|
|
|
16773
16993
|
}
|
|
16774
16994
|
return body;
|
|
16775
16995
|
}
|
|
16776
|
-
var searchCommand4 =
|
|
16996
|
+
var searchCommand4 = defineCommand146({
|
|
16777
16997
|
meta: {
|
|
16778
16998
|
name: "search",
|
|
16779
16999
|
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"
|
|
@@ -16885,7 +17105,7 @@ var searchCommand4 = defineCommand141({
|
|
|
16885
17105
|
});
|
|
16886
17106
|
|
|
16887
17107
|
// src/commands/winning-ads/index.ts
|
|
16888
|
-
var winningAdsCommand =
|
|
17108
|
+
var winningAdsCommand = defineCommand147({
|
|
16889
17109
|
meta: {
|
|
16890
17110
|
name: "winning-ads",
|
|
16891
17111
|
description: `Search the ad-dna corpus of scored "winning" ads for reference creatives to reproduce. Proxied through the Baker backend (BAKER_API_KEY) \u2014 no separate token needed.
|
|
@@ -16925,7 +17145,7 @@ function getCliVersion() {
|
|
|
16925
17145
|
}
|
|
16926
17146
|
|
|
16927
17147
|
// src/cli.ts
|
|
16928
|
-
var main =
|
|
17148
|
+
var main = defineCommand148({
|
|
16929
17149
|
meta: {
|
|
16930
17150
|
name: "baker",
|
|
16931
17151
|
version: getCliVersion(),
|