@oxygen-agent/cli 1.1021.7 → 1.1022.49

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.
Files changed (54) hide show
  1. package/README.md +1 -1
  2. package/dist/command-families/program.js +2 -0
  3. package/dist/command-families/tables/bundle-export.d.ts +2 -1
  4. package/dist/command-families/tables/bundle-export.js +14 -3
  5. package/dist/command-manifest.js +2 -0
  6. package/dist/command-support.d.ts +6 -0
  7. package/dist/command-support.js +61 -9
  8. package/dist/commands/agent.js +2 -2
  9. package/dist/commands/approvals.js +3 -52
  10. package/dist/commands/billing.js +5 -5
  11. package/dist/commands/context.js +2 -2
  12. package/dist/commands/copilot.js +1 -1
  13. package/dist/commands/knowledge.js +2 -2
  14. package/dist/commands/members.d.ts +7 -0
  15. package/dist/commands/members.js +32 -0
  16. package/dist/commands/orgs.js +1 -1
  17. package/dist/commands/publishing.js +36 -2
  18. package/dist/commands/recipes.js +1 -1
  19. package/dist/commands/sequences.js +4 -4
  20. package/dist/commands/suppressions.js +2 -2
  21. package/dist/commands/verify.js +1 -1
  22. package/dist/commands/workspace-export.d.ts +61 -0
  23. package/dist/commands/workspace-export.js +565 -0
  24. package/dist/commands/workspace.js +24 -1
  25. package/dist/help.js +6 -1
  26. package/node_modules/@oxygen/shared/dist/access/permissions.d.ts +101 -0
  27. package/node_modules/@oxygen/shared/dist/access/permissions.js +129 -0
  28. package/node_modules/@oxygen/shared/dist/access/roles.d.ts +73 -0
  29. package/node_modules/@oxygen/shared/dist/access/roles.js +116 -0
  30. package/node_modules/@oxygen/shared/dist/agents/sessions.js +2 -1
  31. package/node_modules/@oxygen/shared/dist/agents/teammates.js +2 -1
  32. package/node_modules/@oxygen/shared/dist/capability-intents/collaboration.js +7 -6
  33. package/node_modules/@oxygen/shared/dist/capability-intents/discovery-and-skills.d.ts +12 -0
  34. package/node_modules/@oxygen/shared/dist/capability-intents/discovery-and-skills.js +54 -0
  35. package/node_modules/@oxygen/shared/dist/capability-intents/discovery-and-skills.rules.d.ts +2 -0
  36. package/node_modules/@oxygen/shared/dist/capability-intents/discovery-and-skills.rules.js +19 -0
  37. package/node_modules/@oxygen/shared/dist/capability-intents/index.generated.js +2 -0
  38. package/node_modules/@oxygen/shared/dist/capability-routes/discovery-and-skills.js +4 -4
  39. package/node_modules/@oxygen/shared/dist/collab.d.ts +0 -29
  40. package/node_modules/@oxygen/shared/dist/collab.js +0 -32
  41. package/node_modules/@oxygen/shared/dist/contracts/browser-operations.js +2 -2
  42. package/node_modules/@oxygen/shared/dist/contracts/customer-operations.js +4 -3
  43. package/node_modules/@oxygen/shared/dist/contracts/publishing-reads.js +1 -1
  44. package/node_modules/@oxygen/shared/dist/copilot/access.d.ts +1 -1
  45. package/node_modules/@oxygen/shared/dist/copilot/access.js +2 -1
  46. package/node_modules/@oxygen/shared/dist/decision-ledger.generated.js +11 -0
  47. package/node_modules/@oxygen/shared/dist/onboarding/guided-activation.js +3 -1
  48. package/node_modules/@oxygen/shared/dist/product-briefing-rules.js +2 -2
  49. package/node_modules/@oxygen/shared/dist/product-doctrine.js +1 -1
  50. package/node_modules/@oxygen/shared/dist/version.d.ts +1 -1
  51. package/node_modules/@oxygen/shared/dist/version.generated.d.ts +1 -1
  52. package/node_modules/@oxygen/shared/dist/version.generated.js +1 -1
  53. package/node_modules/@oxygen/shared/dist/version.js +1 -1
  54. package/package.json +1 -1
package/README.md CHANGED
@@ -34,4 +34,4 @@ oxygen update
34
34
 
35
35
  For product documentation, visit https://oxygen-agent.com/docs. For support, visit https://oxygen-agent.com.
36
36
 
37
- Version: 1.1021.7
37
+ Version: 1.1022.49
@@ -55,6 +55,7 @@ import { registerLoginFamily } from "../commands/login.js";
55
55
  import { registerLogoutFamily } from "../commands/logout.js";
56
56
  import { registerMailboxesFamily } from "../commands/mailboxes.js";
57
57
  import { registerManagedInboxesFamily } from "../commands/managed-inboxes.js";
58
+ import { registerMembersFamily } from "../commands/members.js";
58
59
  import { registerMessagesFamily } from "../commands/messages.js";
59
60
  import { registerNotetakerFamily } from "../commands/notetaker.js";
60
61
  import { registerObservabilityFamily } from "../commands/observability.js";
@@ -165,6 +166,7 @@ export function createProgram() {
165
166
  registerTagsFamily(program, handleAsyncAction);
166
167
  registerCommentsFamily(program, handleAsyncAction);
167
168
  registerApprovalsFamily(program, handleAsyncAction);
169
+ registerMembersFamily(program, handleAsyncAction);
168
170
  registerBlueprintsFamily(program, handleAsyncAction);
169
171
  registerRecipesFamily(program, handleAsyncAction);
170
172
  registerPromptsFamily(program, handleAsyncAction);
@@ -1,7 +1,8 @@
1
+ import { requestOxygen } from "../../http-client.js";
1
2
  import type { WriteStream } from "node:fs";
2
3
  import { TablesExportBundleOptions, TablesExportOptions } from "./options.js";
3
4
  export declare function exportRows(table: string, options: TablesExportOptions): Promise<Record<string, unknown>>;
4
- export declare function exportTableBundle(table: string, options: TablesExportBundleOptions): Promise<Record<string, unknown>>;
5
+ export declare function exportTableBundle(table: string, options: TablesExportBundleOptions, request?: typeof requestOxygen): Promise<Record<string, unknown>>;
5
6
  export declare function writeBundleLine(stream: WriteStream, line: string): Promise<void>;
6
7
  export declare function finishBundleStream(stream: WriteStream): Promise<void>;
7
8
  export declare function assertBundleSerializable(bundle: Record<string, unknown>, rowCount: number): void;
@@ -31,12 +31,15 @@ export async function exportRows(table, options) {
31
31
  };
32
32
  }
33
33
  // skipcq: JS-R1005 — intentional branching across describe/query pagination, column-definition normalization, and output sink (stdout/file)
34
- export async function exportTableBundle(table, options) {
34
+ export async function exportTableBundle(table, options,
35
+ // `workspace export` passes a read that waits out a rate limit; one table
36
+ // alone keeps the plain request.
37
+ request = requestOxygen) {
35
38
  const pageSize = Math.min(readPositiveInt(options.pageSize) ?? TABLE_BUNDLE_DEFAULT_PAGE_SIZE, TABLE_BUNDLE_MAX_PAGE_SIZE);
36
39
  // Pull the canonical schema (incl. enrichment/tool definitions and
37
40
  // semantic types) from `describe`; the paginated query response only
38
41
  // surfaces the user-visible projection.
39
- const describe = await requestOxygen("/api/cli/tables/describe", { method: "POST", body: { table } });
42
+ const describe = await request("/api/cli/tables/describe", { method: "POST", body: { table } });
40
43
  const tableMeta = describe.table ?? null;
41
44
  const columns = (describe.columns ?? []).map(toBundleColumn);
42
45
  const tableId = readRecordString(tableMeta, "id");
@@ -75,7 +78,7 @@ export async function exportTableBundle(table, options) {
75
78
  const requestBody = { table, limit: pageSize };
76
79
  if (cursor)
77
80
  requestBody.cursor = cursor;
78
- const page = await requestOxygen("/api/cli/tables/query", { method: "POST", body: requestBody });
81
+ const page = await request("/api/cli/tables/query", { method: "POST", body: requestBody });
79
82
  pageCount += 1;
80
83
  if (expectedTotal === null) {
81
84
  expectedTotal = readBundleNumber(page.totalCount) ?? readBundleNumber(page.total_count) ?? null;
@@ -87,8 +90,16 @@ export async function exportTableBundle(table, options) {
87
90
  else
88
91
  rows.push(row);
89
92
  }
93
+ const previousCursor = cursor;
90
94
  cursor = typeof page.nextCursor === "string" && page.nextCursor.length > 0 ? page.nextCursor : null;
91
95
  hasMoreFlag = Boolean(page.hasMore);
96
+ // A cursor handed back unchanged would re-read the same page forever.
97
+ if (hasMoreFlag && cursor !== null && cursor === previousCursor) {
98
+ throw new OxygenError("bundle_export_stalled", "The row cursor did not advance between pages; stopped to avoid a loop.", {
99
+ details: { table, exportedCount: rowCount, pages: pageCount },
100
+ exitCode: 1,
101
+ });
102
+ }
92
103
  // Defensive: hasMore=false should always mean cursor=null. If a future
93
104
  // server change ever sets one without the other, stop iterating on
94
105
  // hasMore=false so we don't loop forever.
@@ -115,6 +115,8 @@ const SPENDING_WITHOUT_APPROVAL_COMMANDS = new Set([
115
115
  "sequences test-send",
116
116
  ]);
117
117
  const MUTATING_COMMANDS = new Set([
118
+ // Sets a member's workspace role; `role` is a noun here, not a verb.
119
+ "members role",
118
120
  "domains forwarding get",
119
121
  "domains web-presence set",
120
122
  "domains web-presence bulk",
@@ -403,6 +403,12 @@ export declare function collabTrailer(data: Record<string, unknown>): string[];
403
403
  * to say what changed and keep the deep-link visible.
404
404
  */
405
405
  export declare function formatCollabWriteResult(data: Record<string, unknown>): string;
406
+ /**
407
+ * `members list`. The column that matters is ROLE: an empty overlay means the
408
+ * workspace role decides, which is full member or admin access, never a
409
+ * restricted one.
410
+ */
411
+ export declare function formatWorkspaceMembers(data: Record<string, unknown>): string;
406
412
  export declare function describeProfileSource(source: ProfileSource): string;
407
413
  export declare function formatAutomaticSkillsInstallStatusLines(result?: AutomaticSkillsInstallResult): string[];
408
414
  export declare function ansi(enabled: boolean): {
@@ -10,6 +10,7 @@ import { redactTranscriptSecrets } from "./transcript.js";
10
10
  import { isRecord, readOption } from "./util.js";
11
11
  import { formatCellForDisplay } from "@oxygen/shared/tables/cell-format";
12
12
  import { OxygenError, success } from "@oxygen/shared/cli-result";
13
+ import { WORKSPACE_ROLES } from "@oxygen/shared/access/roles";
13
14
  import { COLLAB_SUBJECT_KINDS, SUBJECT_PATH_FORMS_PROSE, formatSubjectPath, parseSubjectPath, parseSubjectRef } from "@oxygen/shared/collab";
14
15
  import { tableRunSummary } from "@oxygen/shared/tables/run-summary";
15
16
  import { describeWorkflowStatusChange, parseWorkflowStatusChange } from "@oxygen/shared/workflows/status-change";
@@ -1096,20 +1097,71 @@ function collabWriteHeadline(data) {
1096
1097
  }
1097
1098
  // The member-role write returns the membership fields flat, not nested.
1098
1099
  if (typeof data.email === "string") {
1099
- // Granting on a PENDING INVITATION changes nobody's access yet. Saying "is
1100
- // now a client-role member" would tell an agency the client is restricted
1101
- // while that client has not accepted and holds no membership at all.
1100
+ // A role set on a PENDING INVITATION changes nobody's access yet; saying
1101
+ // "is now a Sales rep" would report a role nobody holds.
1102
1102
  if (data.pending_invitation === true) {
1103
- return data.granted === true
1104
- ? `${data.email} has not joined yet — they will land restricted to the client role.`
1105
- : `${data.email} has not joined yet — they will land with full workspace access.`;
1103
+ const onJoin = workspaceRoleLabel(data.oxygen_role);
1104
+ return onJoin
1105
+ ? `${data.email} has not joined yet — they will land as ${onJoin}.`
1106
+ : `${data.email} has not joined yet — they will land with the role they were invited with.`;
1106
1107
  }
1107
- return data.granted === true
1108
- ? `${data.email} is now a client-role member of this workspace.`
1109
- : `${data.email} is back to full workspace access.`;
1108
+ const label = workspaceRoleLabel(data.role) ?? workspaceRoleLabel(data.oxygen_role);
1109
+ if (label)
1110
+ return `${data.email} is now ${/^[AEIOU]/.test(label) ? "an" : "a"} ${label}.`;
1111
+ return `${data.email} now has the role their workspace role gives them.`;
1110
1112
  }
1111
1113
  return "Done.";
1112
1114
  }
1115
+ function workspaceRoleLabel(value) {
1116
+ return WORKSPACE_ROLES.find((role) => role.id === value)?.label ?? null;
1117
+ }
1118
+ /**
1119
+ * `members list`. The column that matters is ROLE: an empty overlay means the
1120
+ * workspace role decides, which is full member or admin access, never a
1121
+ * restricted one.
1122
+ */
1123
+ export function formatWorkspaceMembers(data) {
1124
+ const styles = collabStyles();
1125
+ const members = Array.isArray(data.members) ? data.members.filter(isRecord) : [];
1126
+ const lines = ["", styles.bold(`Workspace members (${members.length})`)];
1127
+ if (members.length === 0) {
1128
+ lines.push(` ${styles.dim("No members resolved for this workspace.")}`);
1129
+ }
1130
+ else {
1131
+ lines.push(...renderTextTable(["EMAIL", "ROLE", "ACCESS"], members.map((member) => [
1132
+ collabText(member.email, collabText(member.user_id)),
1133
+ collabText(member.role_label, workspaceRoleLabel(member.oxygen_role) ?? collabText(member.workspace_role)),
1134
+ collabText(member.access),
1135
+ ])));
1136
+ // Why a restricted role on a given row would be refused, before anyone
1137
+ // tries: on an all-admin workspace EVERY such change is refused, and the
1138
+ // table alone never says so.
1139
+ const blocked = members.filter((member) => member.can_restrict === false);
1140
+ if (blocked.length > 0) {
1141
+ lines.push("", ` ${styles.dim("Cannot take a restricted role:")}`);
1142
+ for (const member of blocked) {
1143
+ lines.push(` ${styles.yellow("!")} ${collabText(member.restrict_blocked_reason)}`);
1144
+ }
1145
+ }
1146
+ }
1147
+ // Invited but not joined. They hold nothing yet, so they are listed apart from
1148
+ // the members rather than mixed in with a role that reads as access.
1149
+ const invitations = Array.isArray(data.pending_invitations)
1150
+ ? data.pending_invitations.filter(isRecord)
1151
+ : [];
1152
+ if (invitations.length > 0) {
1153
+ lines.push("", styles.bold(`Invited, not joined yet (${invitations.length})`));
1154
+ lines.push(...renderTextTable(["EMAIL", "INVITED AS", "ON JOIN", "INVITED"], invitations.map((invitation) => [
1155
+ collabText(invitation.email),
1156
+ collabText(invitation.workspace_role),
1157
+ workspaceRoleLabel(invitation.oxygen_role_on_join) ?? "as invited",
1158
+ formatCollabAge(invitation.invited_at),
1159
+ ])));
1160
+ }
1161
+ lines.push(...collabTrailer(data));
1162
+ lines.push("");
1163
+ return lines.join("\n");
1164
+ }
1113
1165
  export function describeProfileSource(source) {
1114
1166
  switch (source) {
1115
1167
  case "flag": return "from --profile flag";
@@ -68,7 +68,7 @@ export function registerAgentFamily(program, handleAsyncAction) {
68
68
  .requiredOption("--instructions <text>", "Agent instructions for this version.")
69
69
  .option("--model-policy-json <json>", AGENT_MODEL_POLICY_HELP)
70
70
  .option("--tool-policy-json <json>", AGENT_TOOL_POLICY_HELP)
71
- .option("--context-policy-json <json>", "Context policy JSON: on_demand, prefetch, or grounded (seeds the run from the workspace knowledge wiki); optional resolve_args and file_ids.")
71
+ .option("--context-policy-json <json>", "Context policy JSON: on_demand, prefetch, or grounded (seeds a new run with workspace counts and the active pinned voice, brand and positioning pages; in production the grounded seed adds no other wiki pages); optional resolve_args and file_ids.")
72
72
  .option("--skills <csv>", "Comma-separated product skill slugs snapshotted into this immutable version.")
73
73
  .option("--sandbox-policy-json <json>", "Sandbox policy JSON.")
74
74
  .option("--limits-json <json>", "Optional limits JSON; platform hard ceilings still apply.")
@@ -97,7 +97,7 @@ export function registerAgentFamily(program, handleAsyncAction) {
97
97
  .option("--description <text>", "Optional one-line description of the agent's job.")
98
98
  .option("--model-policy-json <json>", AGENT_MODEL_POLICY_HELP)
99
99
  .option("--tool-policy-json <json>", AGENT_TOOL_POLICY_HELP)
100
- .option("--context-policy-json <json>", "Context policy JSON: on_demand, prefetch, or grounded (seeds the run from the workspace knowledge wiki); optional resolve_args and file_ids.")
100
+ .option("--context-policy-json <json>", "Context policy JSON: on_demand, prefetch, or grounded (seeds a new run with workspace counts and the active pinned voice, brand and positioning pages; in production the grounded seed adds no other wiki pages); optional resolve_args and file_ids.")
101
101
  .option("--skills <csv>", "Comma-separated product skill slugs snapshotted into this immutable version.")
102
102
  .option("--sandbox-policy-json <json>", "Sandbox policy JSON.")
103
103
  .option("--limits-json <json>", "Optional limits JSON; platform hard ceilings still apply.")
@@ -1,5 +1,5 @@
1
1
  import { readPositiveInt } from "../cli-values.js";
2
- import { COLLAB_BETA_NOTE, COLLAB_SUBJECT_PATH_HELP, COLLAB_SUBJECT_REF_HELP, collabSnippet, collabStyles, collabText, collabTrailer, collectRepeatable, formatCollabAge, formatCollabWriteResult, handleCollabAction, readCollabPath, renderTextTable, requireCollabSubject } from "../command-support.js";
2
+ import { COLLAB_BETA_NOTE, COLLAB_SUBJECT_PATH_HELP, COLLAB_SUBJECT_REF_HELP, collabSnippet, collabStyles, collabText, collabTrailer, collectRepeatable, formatCollabAge, formatCollabWriteResult, formatWorkspaceMembers, handleCollabAction, readCollabPath, renderTextTable, requireCollabSubject } from "../command-support.js";
3
3
  import { requestOxygen } from "../http-client.js";
4
4
  import { isRecord, readOption } from "../util.js";
5
5
  import { OxygenError } from "@oxygen/shared/cli-result";
@@ -198,55 +198,6 @@ function formatCollabRequestDetail(data) {
198
198
  lines.push("");
199
199
  return lines.join("\n");
200
200
  }
201
- /**
202
- * `approvals client list`. The column that matters is ACCESS: a blank role cell
203
- * means FULL access, not a restricted one, and reading it the other way is how
204
- * an agency convinces itself a client login is limited when it is not.
205
- */
206
- function formatCollabMembers(data) {
207
- const styles = collabStyles();
208
- const members = Array.isArray(data.members) ? data.members.filter(isRecord) : [];
209
- const lines = ["", styles.bold(`Workspace members (${members.length})`)];
210
- if (members.length === 0) {
211
- lines.push(` ${styles.dim("No members resolved for this workspace.")}`);
212
- }
213
- else {
214
- lines.push(...renderTextTable(["EMAIL", "WORKSPACE ROLE", "OXYGEN ROLE", "ACCESS"], members.map((member) => [
215
- collabText(member.email, collabText(member.user_id)),
216
- collabText(member.workspace_role),
217
- member.oxygen_role === "client" ? "client" : "—",
218
- collabText(member.access),
219
- ])));
220
- // Why a grant on a given row would be refused. The payload has carried this
221
- // since the web page needed it; printing it is what stops the terminal from
222
- // being the surface that only finds out by failing — on an all-admin
223
- // workspace EVERY grant is refused, and the table alone never says so.
224
- const blocked = members.filter((member) => member.can_restrict === false);
225
- if (blocked.length > 0) {
226
- lines.push("", ` ${styles.dim("Cannot be restricted to the client role:")}`);
227
- for (const member of blocked) {
228
- lines.push(` ${styles.yellow("!")} ${collabText(member.restrict_blocked_reason)}`);
229
- }
230
- }
231
- }
232
- // Invited but not joined. They hold nothing yet, so they are listed apart from
233
- // the members rather than mixed in with a blank role that reads as access.
234
- const invitations = Array.isArray(data.pending_invitations)
235
- ? data.pending_invitations.filter(isRecord)
236
- : [];
237
- if (invitations.length > 0) {
238
- lines.push("", styles.bold(`Invited, not joined yet (${invitations.length})`));
239
- lines.push(...renderTextTable(["EMAIL", "INVITED AS", "ON JOIN", "INVITED"], invitations.map((invitation) => [
240
- collabText(invitation.email),
241
- collabText(invitation.workspace_role),
242
- invitation.oxygen_role_on_join === "client" ? "client" : "full access",
243
- formatCollabAge(invitation.invited_at),
244
- ])));
245
- }
246
- lines.push(...collabTrailer(data));
247
- lines.push("");
248
- return lines.join("\n");
249
- }
250
201
  function formatCollabRequestWrite(data) {
251
202
  const styles = collabStyles();
252
203
  // The request is nested; the resolved assignee emails are not.
@@ -488,7 +439,7 @@ export function registerApprovalsFamily(program, handleAsyncAction) {
488
439
  }, formatCollabGateList);
489
440
  })))
490
441
  .addCommand(new Command("client")
491
- .description("The restricted login an agency hands its client: read the work, comment on it, decide the approvals assigned to them, nothing else. ADMIN ONLY. Invite them to the workspace first — this grants the overlay on an existing membership.")
442
+ .description("The restricted login an agency hands its client: read the work, comment on it, decide the approvals assigned to them, nothing else. ADMIN ONLY. Same as `oxygen members role <email> --role client`, which also sets the sales rep and viewer roles.")
492
443
  .addCommand(new Command("grant")
493
444
  .description("Restrict a member to the client role. An address that is INVITED but has not joined works too: the role is recorded against the invitation and applies the moment they accept, so you do not have to watch for the acceptance and come back.")
494
445
  .argument("<email>", "Workspace member's email, or a pending invitation's email.")
@@ -513,6 +464,6 @@ export function registerApprovalsFamily(program, handleAsyncAction) {
513
464
  .description("Every member of this workspace and what they may do — the workspace role plus the Oxygen client overlay — followed by anyone invited who has not joined yet, and what they will land as. Also names, per member, why a client grant on them would be refused. Same read the /collab/members page renders.")
514
465
  .option("--json", "Print a JSON envelope.")
515
466
  .action(async (options) => {
516
- await handleCollabAction("approvals client list", options, () => requestOxygen("/api/cli/collab/members"), formatCollabMembers);
467
+ await handleCollabAction("approvals client list", options, () => requestOxygen("/api/cli/collab/members"), formatWorkspaceMembers);
517
468
  })));
518
469
  }
@@ -62,7 +62,7 @@ export function registerBillingFamily(program, handleAsyncAction, billingDocsUrl
62
62
  .command("billing")
63
63
  .description("Plan and managed credit commands. Credits reserved but not yet charged are listed hold by hold with `billing usage --meter holds`. Spend splits into FLEXIBLE (ad-hoc: enrichment, AI, automation — drawn from your free-to-spend balance) and FIXED recurring per-resource monthly commitments blocked out of it; see `billing commitments`. THREE CLOCKS, deliberately different: the CREDIT CYCLE that `billing allowance` reports against (your plan's monthly grant window); each resource's own COMMITMENT RENEWAL, anchored to the day you connected it, so `billing commitments --json` next_due_at rarely matches the cycle end; and your SUBSCRIPTION PERIOD in `billing balance` (annual plans span many credit cycles). A number from one clock will not reconcile against another. On a plan that pays for several workspaces, `billing usage --group-by workspace` totals what each one spent. To price a month of outreach before building it (leads, enrichment, sequence steps, senders), run `billing estimate`. Failed-payment grace, suspension, and recovery: " + billingDocsUrl + ".")
64
64
  .addCommand(new Command("change")
65
- .description("Create an approval link (`approval_url`) to start or change a plan; no charge or plan change until confirmation. First purchase needs an admin/owner; existing-plan changes allow any unrestricted member. Compare all six prices, credits and yearly terms with `billing balance` first. Use --interval year --term year to pay the full discounted year upfront: the $99 plan costs $990 per year before tax. Credits arrive monthly during the paid year. On a workspace that has never had a plan, the Checkout for any monthly plan from $49 up carries the first-month offer, half its first month, while its 24-hour window is open (`offer`; `billing balance` lists every size under `first_month_offer.plans`): `amount_due_now` is then the discounted first month and `next_invoice_total` the regular price, both before tax. Creating that Checkout starts the window if nothing has started it yet. `first_month_offer` says whether the offer covers the chosen plan (`applies`) and names the plan it does cover (`plan`, the $99 plan by default: $49 for its first month); a term it misses (yearly) still gets its own Checkout, so relay the offer before the human pays. Prepaid yearly upgrades apply immediately with proration; downgrades and switching to monthly wait until the paid year ends. Switching from monthly to yearly starts at the next paid-period boundary. Existing yearly installment plans keep their payments until conversion at the yearly commitment end. Omit interval and term to preserve the current contract. For an existing subscription, a yearly preview returns charges, start and term-end dates; nothing changes until separate confirmation.")
65
+ .description("Create an approval link (`approval_url`) to start or change a plan; no charge or plan change until confirmation. Needs a workspace admin or owner. Compare all six prices, credits and yearly terms with `billing balance` first. Use --interval year --term year to pay the full discounted year upfront: the $99 plan costs $990 per year before tax. Credits arrive monthly during the paid year. On a workspace that has never had a plan, the Checkout for any monthly plan from $49 up carries the first-month offer, half its first month, while its 24-hour window is open (`offer`; `billing balance` lists every size under `first_month_offer.plans`): `amount_due_now` is then the discounted first month and `next_invoice_total` the regular price, both before tax. Creating that Checkout starts the window if nothing has started it yet. `first_month_offer` says whether the offer covers the chosen plan (`applies`) and names the plan it does cover (`plan`, the $99 plan by default: $49 for its first month); a term it misses (yearly) still gets its own Checkout, so relay the offer before the human pays. Prepaid yearly upgrades apply immediately with proration; downgrades and switching to monthly wait until the paid year ends. Switching from monthly to yearly starts at the next paid-period boundary. Existing yearly installment plans keep their payments until conversion at the yearly commitment end. Omit interval and term to preserve the current contract. For an existing subscription, a yearly preview returns charges, start and term-end dates; nothing changes until separate confirmation.")
66
66
  .requiredOption("--to <plan>",
67
67
  // Derived from the catalog, never retyped: this help text is the only
68
68
  // place a customer's agent learns which plans exist, and it named
@@ -161,7 +161,7 @@ export function registerBillingFamily(program, handleAsyncAction, billingDocsUrl
161
161
  await handleAsyncAction("billing seats", options, () => requestOxygen("/api/cli/billing/seats"));
162
162
  })
163
163
  .addCommand(new Command("set")
164
- .description("Manage legacy dollar sending seats for one channel; check `billing seats` for retirement status. The quantity is ABSOLUTE, not a delta: `--quantity 3` means you end up with three, so a retried command cannot buy extra. Increasing charges the card pro rata immediately; decreasing credits you pro rata. Reducing below the number of senders you have connected is REFUSED and names how many to disconnect first, because an orphaned sender is one you keep paying a provider for while Oxygen has stopped honouring it. An email_sender reduction is refused with `seat_allocation_unavailable` (503) while the workspace's mailbox count cannot be read; retry it in a moment. Once seats are retired, any increase is refused with `seats_retired` and lowering held seats still works. Charges real money.")
164
+ .description("Manage legacy dollar sending seats for one channel (admin or owner only); check `billing seats` for retirement status. The quantity is ABSOLUTE, not a delta: `--quantity 3` means you end up with three, so a retried command cannot buy extra. Increasing charges the card pro rata immediately; decreasing credits you pro rata. Reducing below the number of senders you have connected is REFUSED and names how many to disconnect first, because an orphaned sender is one you keep paying a provider for while Oxygen has stopped honouring it. An email_sender reduction is refused with `seat_allocation_unavailable` (503) while the workspace's mailbox count cannot be read; retry it in a moment. Once seats are retired, any increase is refused with `seats_retired` and lowering held seats still works. Charges real money.")
165
165
  .requiredOption("--seat-key <kind>", "linkedin, whatsapp, phone_number, or email_sender.")
166
166
  .requiredOption("--quantity <n>", "Total seats to hold for this channel, 0 or more.")
167
167
  .option("--json", "Print a JSON envelope.")
@@ -311,7 +311,7 @@ export function registerBillingFamily(program, handleAsyncAction, billingDocsUrl
311
311
  }));
312
312
  }))
313
313
  .addCommand(new Command("cancel")
314
- .description("Turn off subscription renewal. For a yearly commitment paid monthly, remaining monthly payments continue through commitment_ends_at; the plan stays usable until then. Other plans end at their paid period or trial end with no further subscription renewal charge. This command costs no Oxygen credits. Separately funded external resources keep renewing; preview `workspace infrastructure-exit` to end those too. Prints the end date; undo before then with billing resume.")
314
+ .description("Turn off subscription renewal; admin or owner only. For a yearly commitment paid monthly, remaining monthly payments continue through commitment_ends_at; the plan stays usable until then. Other plans end at their paid period or trial end with no further subscription renewal charge. This command costs no Oxygen credits. Separately funded external resources keep renewing; preview `workspace infrastructure-exit` to end those too. Prints the end date; undo before then with billing resume.")
315
315
  .addOption(new Option("--reason <reason>", "Why you are cancelling; ask the customer.").choices([...CANCELLATION_REASON_VALUES]))
316
316
  .option("--comment <text>", "Written cancellation feedback (1–2,000 characters).")
317
317
  .option("--json", "Print a JSON envelope.")
@@ -326,7 +326,7 @@ export function registerBillingFamily(program, handleAsyncAction, billingDocsUrl
326
326
  }));
327
327
  }))
328
328
  .addCommand(new Command("resume")
329
- .description("Remove a scheduled cancellation so the subscription renews (or the trial converts) normally. Free (no fee, no credits). Prints the next charge date and amount.")
329
+ .description("Remove a scheduled cancellation so the subscription renews (or the trial converts) normally; admin or owner only. Free (no fee, no credits). Prints the next charge date and amount.")
330
330
  .option("--json", "Print a JSON envelope.")
331
331
  .action(async (options) => {
332
332
  await handleAsyncAction("billing resume", options, () => requestOxygen("/api/cli/billing/cancel", {
@@ -341,7 +341,7 @@ export function registerBillingFamily(program, handleAsyncAction, billingDocsUrl
341
341
  await handleAsyncAction("billing retention-offer", options, () => requestOxygen("/api/cli/billing/cancel", { method: "POST", body: { action: "offer" } }));
342
342
  }))
343
343
  .addCommand(new Command("retain")
344
- .description("Stay subscribed with the one-month retention discount from billing retention-offer. Restores renewal if cancellation was scheduled. No charge today; the normal price returns afterwards.")
344
+ .description("Stay subscribed with the one-month retention discount from billing retention-offer; admin or owner only. Restores renewal if cancellation was scheduled. No charge today; the normal price returns afterwards.")
345
345
  .requiredOption("--offer <id>", "The offer_id from the retention offer preview.")
346
346
  .option("--json", "Print a JSON envelope.")
347
347
  .action(async (options) => {
@@ -138,7 +138,7 @@ export function registerContextFamily(program, handleAsyncAction) {
138
138
  .option("--body <text>", "Asset body text.")
139
139
  .option("--data-json <json>", "Flexible JSON object for structured asset data.")
140
140
  .option("--asset-json <json>", "Full asset JSON object. CLI flags override matching fields.")
141
- .option("--default", "Ask to pin as the canonical default for its type (auto-applied to copy generation). For brand, voice, positioning and playbooks the asset saves unpinned and the pin waits for approval of a proposal (pin.ok false; oxygen knowledge proposals approve <id>); other types pin at once.")
141
+ .option("--default", "Ask to pin as the canonical default for its type; only an active pinned brand, voice or positioning asset is auto-applied to AI copy. For brand, voice, positioning and playbooks the asset saves unpinned and the pin waits for approval of a proposal (pin.ok false; oxygen knowledge proposals approve <id>); other types pin at once.")
142
142
  .option("--json", "Print a JSON envelope.")
143
143
  .action(async (options) => {
144
144
  await handleAsyncAction("context asset upsert", options, () => requestOxygen("/api/cli/context/assets/upsert", {
@@ -147,7 +147,7 @@ export function registerContextFamily(program, handleAsyncAction) {
147
147
  }));
148
148
  }))
149
149
  .addCommand(new Command("set-default")
150
- .description("Pin a context asset as the canonical default for its type. The canonical brand/voice/positioning docs are auto-applied to AI copy generation. For brand, voice, positioning and playbooks a pin or unpin files a proposal a human approves (oxygen knowledge proposals approve <id>) and fails with knowledge_approval_required; other types pin at once.")
150
+ .description("Pin a context asset as the canonical default for its type. Of pinned assets, only an active brand, voice or positioning doc is auto-applied to AI copy generation. For brand, voice, positioning and playbooks a pin or unpin files a proposal a human approves (oxygen knowledge proposals approve <id>) and fails with knowledge_approval_required; other types pin at once.")
151
151
  .argument("<asset_id>", "Context asset UUID.")
152
152
  .option("--off", "Unpin instead of pin (clears the canonical default for this type).")
153
153
  .option("--json", "Print a JSON envelope.")
@@ -330,7 +330,7 @@ function waitForCopilotTurn(options) {
330
330
  export function registerCopilotFamily(program, handleAsyncAction) {
331
331
  program
332
332
  .command("copilot")
333
- .description("Workspace Copilot: an attended agent you drive turn by turn from the terminal. Start a session, send it messages and watch the reply stream, approve the actions it proposes, then cancel when done. Managed inference uses workspace credits; paid or external actions keep their own approval gates. Web: /copilot.")
333
+ .description("Workspace Copilot: an attended agent you drive turn by turn from the terminal. Start a session, send it messages and watch the reply stream, approve the actions it proposes, then cancel when done. Managed inference uses workspace credits; paid or external actions keep their own approval gates. On the web, Home opens the first Oxygent's chat, and a session started here opens read-only at /copilot/<id>.")
334
334
  .addCommand(new Command("dev-eval")
335
335
  .description("DEV staff owner only: immutable USD30 campaign and supplier ledger; classify dispatches guarded inference.")
336
336
  .argument("<operation>", "create, register, readiness, ledger, effects, classify, accept-pilot or end")
@@ -385,7 +385,7 @@ export function registerKnowledgeFamily(program, handleAsyncAction) {
385
385
  .option("--domain <domain>", "Company domain to research. Defaults to the recorded workspace domain; if none is available, the preview asks for one.")
386
386
  .option("--linkedin <url>", "Optional company LinkedIn URL to use for the direct lookup. The returned company website must still match the domain.")
387
387
  .option("--live", "Authorize this manual run to spend and write. Requires --max-credits. Without it the command previews and nothing is billed.")
388
- .option("--approved", "Same as --live. Accepted because the global help footer names --approved as the way to authorize a credit-spending command.")
388
+ .option("--approved", "Same as --live. Accepted because other paid runs authorize spend with --approved.")
389
389
  .option("--max-credits <credits>", `Hard credit ceiling for the whole pass. Required with --live, and clamped server-side to ${KNOWLEDGE_BOOTSTRAP_MAX_CREDITS}.`)
390
390
  .option("--force", "Re-arm past an existing once-ever marker, the one deliberate way to research the same workspace twice. Without --live it only previews the re-arm for free: nothing is cleared or written. With --live it replaces the marker with a new pass and spends again.")
391
391
  .option("--json", "Print a JSON envelope.")
@@ -558,7 +558,7 @@ export function registerKnowledgeFamily(program, handleAsyncAction) {
558
558
  });
559
559
  }))
560
560
  .addCommand(new Command("pin")
561
- .description("Pin a knowledge wiki page as the canonical default for its type. Canonical voice/brand/positioning pages are auto-applied to AI copy generation.")
561
+ .description("Pin a knowledge wiki page as the canonical default for its type. Of pinned pages, only an active voice, brand or positioning page is auto-applied to AI copy.")
562
562
  .argument("<slug_or_id>", "Page slug or UUID.")
563
563
  .option("--canonical", "Pin as the canonical default for its type (default).")
564
564
  .option("--no-canonical", "Unpin instead of pin (clears the canonical default for this type).")
@@ -0,0 +1,7 @@
1
+ import { Command } from "commander";
2
+ import { ExtractedCommandActionHandler } from "../command-support.js";
3
+ /**
4
+ * Workspace roles (ADR 0033): who can do what, and changing it. The same reads
5
+ * and writes as the workspace's /collab/members page.
6
+ */
7
+ export declare function registerMembersFamily(program: Command, _handleAsyncAction: ExtractedCommandActionHandler): void;
@@ -0,0 +1,32 @@
1
+ import { WORKSPACE_ROLES } from "@oxygen/shared/access/roles";
2
+ import { Command } from "commander";
3
+ import { formatCollabWriteResult, formatWorkspaceMembers, handleCollabAction } from "../command-support.js";
4
+ import { requestOxygen } from "../http-client.js";
5
+ import { readOption } from "../util.js";
6
+ const ROLE_HELP = WORKSPACE_ROLES.map((role) => `${role.id} (${role.label}): ${role.summary}`).join(" ");
7
+ /**
8
+ * Workspace roles (ADR 0033): who can do what, and changing it. The same reads
9
+ * and writes as the workspace's /collab/members page.
10
+ */
11
+ export function registerMembersFamily(program, _handleAsyncAction) {
12
+ program
13
+ .command("members")
14
+ .description("Workspace members and their roles: admin, member, sales rep, viewer and client. Reading is open to every member; changing a role is ADMIN ONLY.")
15
+ .addCommand(new Command("list")
16
+ .description("Every member, their role and what it lets them do, then anyone invited who has not joined yet and the role they will land with. Names, per member, why a restricted role would be refused.")
17
+ .option("--json", "Print a JSON envelope.")
18
+ .action(async (options) => {
19
+ await handleCollabAction("members list", options, () => requestOxygen("/api/cli/collab/members"), formatWorkspaceMembers);
20
+ }))
21
+ .addCommand(new Command("role")
22
+ .description(`Set a member's role. ADMIN ONLY. ${ROLE_HELP} An invited address that has not joined yet takes any role but admin, applied the moment they accept. You cannot change your own role, and a workspace admin must be made a member before taking a restricted role.`)
23
+ .argument("<email>", "The member's email, or a pending invitation's email.")
24
+ .requiredOption("--role <role>", `One of ${WORKSPACE_ROLES.map((role) => role.id).join(", ")}.`)
25
+ .option("--json", "Print a JSON envelope.")
26
+ .action(async (email, options) => {
27
+ await handleCollabAction("members role", options, () => requestOxygen("/api/cli/collab/members/role", {
28
+ method: "POST",
29
+ body: { email, role: readOption(options.role) },
30
+ }), formatCollabWriteResult);
31
+ }));
32
+ }
@@ -224,7 +224,7 @@ export function registerOrgsFamily(program, handleAsyncAction) {
224
224
  }));
225
225
  }))
226
226
  .addCommand(new Command("member-role")
227
- .description("Move a member between the admin and member workspace roles. ADMIN ONLY. This is the one Clerk membership change Oxygen makes — inviting people is still done in workspace settings. Use it to demote an admin before `approvals client grant`: a workspace admin's role overrides the restricted client role, so the grant is refused until they are a plain member.")
227
+ .description("Move a member between the admin and member workspace roles. ADMIN ONLY. This is the one Clerk membership change Oxygen makes — inviting people is still done in workspace settings. `oxygen members role` sets every role, including sales rep, viewer and client.")
228
228
  .argument("<email>", "Workspace member's email.")
229
229
  .requiredOption("--role <role>", "admin or member.")
230
230
  .option("--json", "Print a JSON envelope.")
@@ -10,7 +10,7 @@ import { OxygenError } from "@oxygen/shared/cli-result";
10
10
  import { publishingAmplificationListQueryContract, publishingAmplificationActionsQueryContract, publishingNotesQueryContract, publishingRevisionsQueryContract, publishingAnalyticsQueryContract, publishingReadQueryParams } from "@oxygen/shared/contracts/publishing-reads";
11
11
  import { Command } from "commander";
12
12
  import { openAsBlob } from "node:fs";
13
- import { basename } from "node:path";
13
+ import { basename, resolve } from "node:path";
14
14
  function buildPublishingPostsListPath(options) {
15
15
  const query = new URLSearchParams();
16
16
  const filters = {
@@ -490,6 +490,22 @@ function buildPublishingAnalyticsPath(base, params) {
490
490
  const suffix = [query.toString(), ...lists].filter(Boolean).join("&");
491
491
  return suffix ? `${base}?${suffix}` : base;
492
492
  }
493
+ async function runPublishingAnalyticsExport(options) {
494
+ const path = readOption(options.output);
495
+ if (!path)
496
+ throw new OxygenError("invalid_request", "--output is required.", { exitCode: 2 });
497
+ const output = resolve(path);
498
+ const saved = await requestOxygen(buildPublishingAnalyticsPath("/api/cli/publishing/analytics/export", {
499
+ format: "csv",
500
+ channel: readOption(options.channel),
501
+ range: readOption(options.range),
502
+ from: readOption(options.from),
503
+ to: readOption(options.to),
504
+ accounts: readPublishingAnalyticsAccounts(options.account),
505
+ tags: readPublishingAnalyticsAccounts(options.tag),
506
+ }), { binaryOutputPath: output });
507
+ return { path: saved.path, bytes: saved.bytes, message: `Saved post analytics to ${saved.path}.` };
508
+ }
493
509
  function publishingReadQueryPath(path, contract, options) {
494
510
  const [base = path, existing] = path.split("?", 2);
495
511
  const query = new URLSearchParams(existing);
@@ -498,6 +514,7 @@ function publishingReadQueryPath(path, contract, options) {
498
514
  return query.size ? `${base}?${query}` : base;
499
515
  }
500
516
  const PUBLISHING_ANALYTICS_ACCOUNT_HELP = "An account key from the summary's accounts list, or a LinkedIn sender id from `oxygen senders list`. Repeatable.";
517
+ const PUBLISHING_ANALYTICS_TAG_HELP = "Count only posts carrying this tag (case-insensitive); the summary's tags list names them. Repeatable: a post counts when it carries any of them.";
501
518
  /** Repeated and/or comma-separated `--account` values, trimmed and de-duplicated. */
502
519
  function readPublishingAnalyticsAccounts(values) {
503
520
  return [...new Set((values ?? []).flatMap((value) => splitCommaList(value)))];
@@ -1207,6 +1224,7 @@ export function registerPublishingFamily(program, handleAsyncAction) {
1207
1224
  .option("--limit <n>", "Top posts to return. Defaults to 10, maximum 50.")
1208
1225
  .option("--sort <metric>", "Rank top posts by engagements (default; reactions + comments + reposts), impressions, reactions, comments, or reposts. `leader` reports the top post's lead over the runner-up and the median.")
1209
1226
  .option("--account <key>", PUBLISHING_ANALYTICS_ACCOUNT_HELP, collectRepeatable, [])
1227
+ .option("--tag <tag>", PUBLISHING_ANALYTICS_TAG_HELP, collectRepeatable, [])
1210
1228
  .option("--json", "Print a JSON envelope.")
1211
1229
  .action(async (options) => {
1212
1230
  const accounts = readPublishingAnalyticsAccounts(options.account);
@@ -1220,6 +1238,7 @@ export function registerPublishingFamily(program, handleAsyncAction) {
1220
1238
  limit: readOption(options.limit),
1221
1239
  sort: readOption(options.sort),
1222
1240
  accounts,
1241
+ tags: readPublishingAnalyticsAccounts(options.tag),
1223
1242
  }));
1224
1243
  return data;
1225
1244
  });
@@ -1234,6 +1253,7 @@ export function registerPublishingFamily(program, handleAsyncAction) {
1234
1253
  .option("--to <date>", "Custom inclusive end date.")
1235
1254
  .option("--tz <zone>", "IANA time zone for day boundaries, e.g. Europe/Berlin. Defaults to UTC.")
1236
1255
  .option("--account <key>", PUBLISHING_ANALYTICS_ACCOUNT_HELP, collectRepeatable, [])
1256
+ .option("--tag <tag>", `${PUBLISHING_ANALYTICS_TAG_HELP} Follower counts ignore it.`, collectRepeatable, [])
1237
1257
  .option("--json", "Print a JSON envelope.")
1238
1258
  .action(async (options) => {
1239
1259
  await handleAsyncAction("publishing analytics timeseries", options, () => requestOxygen(buildPublishingAnalyticsPath("/api/cli/publishing/analytics/timeseries", {
@@ -1243,7 +1263,21 @@ export function registerPublishingFamily(program, handleAsyncAction) {
1243
1263
  to: readOption(options.to),
1244
1264
  tz: readOption(options.tz),
1245
1265
  accounts: readPublishingAnalyticsAccounts(options.account),
1266
+ tags: readPublishingAnalyticsAccounts(options.tag),
1246
1267
  })));
1268
+ }))
1269
+ .addCommand(new Command("export")
1270
+ .description("Save post analytics as a CSV file, one row per published post in the range, newest first (at most 10,000): date, network, author, title, text, tags and the latest stored impressions, reactions, comments, reposts and engagements. An unknown number is an empty cell, never 0. Read-only: no provider call, 0 credits.")
1271
+ .requiredOption("--output <file>", "CSV file to create. An existing file is never overwritten.")
1272
+ .option("--channel <channel>", "linkedin or x. Omit for both networks.")
1273
+ .option("--range <range>", "Publication window: 7d, 30d (default), 90d, or 365d.")
1274
+ .option("--from <date>", "Custom inclusive UTC start date.")
1275
+ .option("--to <date>", "Custom inclusive UTC end date.")
1276
+ .option("--account <key>", PUBLISHING_ANALYTICS_ACCOUNT_HELP, collectRepeatable, [])
1277
+ .option("--tag <tag>", PUBLISHING_ANALYTICS_TAG_HELP, collectRepeatable, [])
1278
+ .option("--json", "Print a JSON envelope.")
1279
+ .action(async (options) => {
1280
+ await handleAsyncAction("publishing analytics export", options, () => runPublishingAnalyticsExport(options));
1247
1281
  }))
1248
1282
  .addCommand(addContractFlags(new Command("post"), publishingAnalyticsQueryContract)
1249
1283
  .description("One post's stored daily metric series, totals, growth curve, 24h/7d benchmarks against the workspace median, and earned-media value. EMV is impressions-derived; absent impressions return a reason instead of a made-up number. Read-only: no provider call, 0 credits.")
@@ -1276,7 +1310,7 @@ export function registerPublishingFamily(program, handleAsyncAction) {
1276
1310
  body: { cpm: parseJsonObject(options.cpmJson ?? "") },
1277
1311
  }));
1278
1312
  }))
1279
- .addHelpText("after", "\nExamples (stored snapshots, 0 credits, no provider call):\n oxygen publishing analytics summary --channel linkedin --range 30d --sort impressions --json\n oxygen publishing analytics timeseries --channel linkedin --range 30d --tz Europe/Berlin --json\n\nTotals, leader and trends combine every posting account; `accounts` lists them and `--account <key>` counts only the ones you name. `top_posts[].account` names each post's author.\nWhy a metric is null: every null carries a reason in `null_reasons`:\n not_exposed_by_provider the rail OXYGEN currently reads through never returns it (`capabilities.metrics.<metric>.reason` names the limit)\n not_synced_yet no background snapshot has landed yet\n not_returned_by_provider snapshots exist but the provider left it out (LinkedIn shows impressions only to the post's author)\nSee also: the oxygen-publishing product skill (`oxygen skills get oxygen-publishing --file references/analytics.md`) for reading LinkedIn performance.\n"))
1313
+ .addHelpText("after", "\nExamples (stored snapshots, 0 credits, no provider call):\n oxygen publishing analytics summary --channel linkedin --range 30d --sort impressions --json\n oxygen publishing analytics timeseries --channel linkedin --range 30d --tz Europe/Berlin --json\n oxygen publishing analytics summary --range 90d --tag launch --json\n oxygen publishing analytics export --range 90d --output posts.csv\n\nTotals, leader and trends combine every posting account; `accounts` lists them and `--account <key>` counts only the ones you name. `top_posts[].account` names each post's author. `tags` breaks the range down by tag (a post with several tags counts under each) and `--tag <tag>` counts only posts carrying it.\nWhy a metric is null: every null carries a reason in `null_reasons`:\n not_exposed_by_provider the rail OXYGEN currently reads through never returns it (`capabilities.metrics.<metric>.reason` names the limit)\n not_synced_yet no background snapshot has landed yet\n not_returned_by_provider snapshots exist but the provider left it out (LinkedIn shows impressions only to the post's author)\nSee also: the oxygen-publishing product skill (`oxygen skills get oxygen-publishing --file references/analytics.md`) for reading LinkedIn performance.\n"))
1280
1314
  .addCommand(new Command("import")
1281
1315
  .description("Bulk-load scheduled posts from a .csv or .json file. Dry-run by DEFAULT: it parses, lints, and reports invalid rows while writing nothing. Pass --approved to actually write. Imported posts land as drafts that still need approval — import never approves and never publishes. A row whose idempotency_key was already used is skipped, so re-importing the same file cannot duplicate the queue.")
1282
1316
  .requiredOption("--file <path>", "Path to a .csv (header row) or .json file ([rows] or { rows: [...] }). Columns: content_text, publish_at, and optionally sender_account_id, provider, timezone, title, first_comment, tags, idempotency_key. A publish_at without Z or an offset is wall-clock time in the row's timezone, else its sender's, else UTC.")
@@ -64,7 +64,7 @@ export function registerRecipesFamily(program, handleAsyncAction) {
64
64
  }));
65
65
  }))
66
66
  .addCommand(new Command("install")
67
- .description("Install a recipe into the workspace wiki as a playbook page (revisioned, retrieval-grounded, with per-version provenance).")
67
+ .description("Install a recipe into the workspace wiki as a playbook page (revisioned, with per-version provenance).")
68
68
  .argument("<slug>", "Recipe slug, e.g. outbound-pilot-50.")
69
69
  .option("--slug <wiki_slug>", "Override the target wiki slug (default playbook-<recipe-slug>).")
70
70
  .option("--draft", "Install as a draft page (drafts never ground AI actions until activated).")