primcli 3.0.0-preview.25 → 3.0.0-preview.27

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.
@@ -1,6 +1,6 @@
1
1
  import { $t as getThread, Bt as getEndpoint, C as parseRetryAfter, H as assertAwaitingFilterRows, J as isAwaitingRejectedError, U as awaitingRejectedError, V as ReplyStateUnsupportedError, Vn as sdk_gen_exports, W as ensureSearchReportsReplyState, X as replyStateSurfaceForOperation, Yt as getOwnGrant, at as expectedAutomatedVerdicts, et as AutomatedFilterUnsupportedError, it as ensureSearchReportsAutomated, nt as automatedRejectedError, pn as listEndpoints, rt as automatedSurfaceForOperation, st as isAutomatedRejectedError, tt as assertAutomatedVerdict, un as listDomains, zt as getEmail } from "./repeats-Dj_o6c-X-CK1wU9lP.js";
2
- import { a as canonicalCommandId, i as canonicalCliText, r as canonicalBodyFlagName } from "./cli-command-names-DiNDwwDX.js";
3
- import { C as resolveCliAuth, I as agentProfilesDirectory, M as AGENT_PROFILE_ENV, P as agentProfileDirectory, Q as loadActiveAgentPass, S as normalizeApiBaseUrl, T as saveSignupCredentials, U as requireDefaultLoginProfile, b as detectPrimitiveKeyEnvMisname, ct as PrimitiveApiClient, f as validateCliHeaderName, h as cliAccessTokenExpiresAt, i as loadCliConfig, l as resolveConfigEnvironment, m as acquireCliCredentialsLock, ot as detectRuntimeSession, p as validateCliHeaderValue, v as deleteCliCredentials, w as saveCliCredentials, x as loadCliCredentials, z as loadConnectedAgentProfile } from "./cli-config-D2MU7PiU.js";
2
+ import { a as canonicalCommandId, i as canonicalCliText, r as canonicalBodyFlagName } from "./cli-command-names-no0f7d7s.js";
3
+ import { B as agentProfileDirectory, C as normalizeApiBaseUrl, E as saveSignupCredentials, G as loadConnectedAgentProfile, H as agentProfilesDirectory, R as AGENT_PROFILE_ENV, S as loadCliCredentials, T as saveCliCredentials, Y as requireDefaultLoginProfile, b as detectPrimitiveKeyEnvMisname, f as validateCliHeaderName, ft as detectRuntimeSession, h as cliAccessTokenExpiresAt, i as loadCliConfig, l as resolveConfigEnvironment, m as acquireCliCredentialsLock, mt as PrimitiveApiClient, p as validateCliHeaderValue, rt as loadActiveAgentPass, v as deleteCliCredentials, w as resolveCliAuth } from "./cli-config-CwZJQIcn.js";
4
4
  import "./oclif/global-org-flag.js";
5
5
  import { a as assertRequiredBodyFields, i as operationHelpInputs } from "./help-inputs-NGARVZL_.js";
6
6
  import { o as thrownErrorBody } from "./json-output-BMZrLH47.js";
@@ -988,7 +988,9 @@ const operationManifest = [
988
988
  },
989
989
  "action": {
990
990
  "type": "string",
991
+ "minLength": 1,
991
992
  "maxLength": 128,
993
+ "pattern": "^[a-z0-9][a-z0-9._:-]{0,127}$",
992
994
  "description": "Lowercase action slug (for example `brex.upload_invoice`)."
993
995
  },
994
996
  "status": {
@@ -1034,9 +1036,8 @@ const operationManifest = [
1034
1036
  },
1035
1037
  "url": {
1036
1038
  "type": "string",
1037
- "format": "uri",
1038
1039
  "maxLength": 2048,
1039
- "description": "HTTP(S) link to the external record."
1040
+ "description": "HTTP(S) link to the external record (validated as an `http://` or `https://` URL)."
1040
1041
  },
1041
1042
  "label": {
1042
1043
  "type": "string",
@@ -1052,17 +1053,20 @@ const operationManifest = [
1052
1053
  },
1053
1054
  "run_id": {
1054
1055
  "type": ["string", "null"],
1055
- "maxLength": 128
1056
+ "minLength": 1,
1057
+ "maxLength": 128,
1058
+ "pattern": "^[A-Za-z0-9._:/-]{1,128}$"
1056
1059
  },
1057
1060
  "trace_url": {
1058
1061
  "type": ["string", "null"],
1059
- "format": "uri",
1060
- "maxLength": 2048
1062
+ "maxLength": 2048,
1063
+ "description": "Optional `http://` or `https://` URL linking to an execution trace for this activity."
1061
1064
  },
1062
1065
  "idempotency_key": {
1063
1066
  "type": "string",
1064
1067
  "minLength": 1,
1065
- "maxLength": 255
1068
+ "maxLength": 255,
1069
+ "pattern": "^[!-~]{1,255}$"
1066
1070
  },
1067
1071
  "visibility": {
1068
1072
  "type": "string",
@@ -1213,9 +1217,8 @@ const operationManifest = [
1213
1217
  },
1214
1218
  "url": {
1215
1219
  "type": "string",
1216
- "format": "uri",
1217
1220
  "maxLength": 2048,
1218
- "description": "HTTP(S) link to the external record."
1221
+ "description": "HTTP(S) link to the external record (validated as an `http://` or `https://` URL)."
1219
1222
  },
1220
1223
  "label": {
1221
1224
  "type": "string",
@@ -1369,7 +1372,9 @@ const operationManifest = [
1369
1372
  },
1370
1373
  "action": {
1371
1374
  "type": "string",
1375
+ "minLength": 1,
1372
1376
  "maxLength": 128,
1377
+ "pattern": "^[a-z0-9][a-z0-9._:-]{0,127}$",
1373
1378
  "description": "Lowercase action slug (for example `brex.upload_invoice`)."
1374
1379
  },
1375
1380
  "status": {
@@ -1419,9 +1424,8 @@ const operationManifest = [
1419
1424
  },
1420
1425
  "url": {
1421
1426
  "type": "string",
1422
- "format": "uri",
1423
1427
  "maxLength": 2048,
1424
- "description": "HTTP(S) link to the external record."
1428
+ "description": "HTTP(S) link to the external record (validated as an `http://` or `https://` URL)."
1425
1429
  },
1426
1430
  "label": {
1427
1431
  "type": "string",
@@ -1437,17 +1441,20 @@ const operationManifest = [
1437
1441
  },
1438
1442
  "run_id": {
1439
1443
  "type": ["string", "null"],
1440
- "maxLength": 128
1444
+ "minLength": 1,
1445
+ "maxLength": 128,
1446
+ "pattern": "^[A-Za-z0-9._:/-]{1,128}$"
1441
1447
  },
1442
1448
  "trace_url": {
1443
1449
  "type": ["string", "null"],
1444
- "format": "uri",
1445
- "maxLength": 2048
1450
+ "maxLength": 2048,
1451
+ "description": "Optional `http://` or `https://` URL linking to an execution trace for this activity."
1446
1452
  },
1447
1453
  "idempotency_key": {
1448
1454
  "type": "string",
1449
1455
  "minLength": 1,
1450
- "maxLength": 255
1456
+ "maxLength": 255,
1457
+ "pattern": "^[!-~]{1,255}$"
1451
1458
  },
1452
1459
  "visibility": {
1453
1460
  "type": "string",
@@ -1598,9 +1605,8 @@ const operationManifest = [
1598
1605
  },
1599
1606
  "url": {
1600
1607
  "type": "string",
1601
- "format": "uri",
1602
1608
  "maxLength": 2048,
1603
- "description": "HTTP(S) link to the external record."
1609
+ "description": "HTTP(S) link to the external record (validated as an `http://` or `https://` URL)."
1604
1610
  },
1605
1611
  "label": {
1606
1612
  "type": "string",
@@ -2087,9 +2093,8 @@ const operationManifest = [
2087
2093
  },
2088
2094
  "url": {
2089
2095
  "type": "string",
2090
- "format": "uri",
2091
2096
  "maxLength": 2048,
2092
- "description": "HTTP(S) link to the external record."
2097
+ "description": "HTTP(S) link to the external record (validated as an `http://` or `https://` URL)."
2093
2098
  },
2094
2099
  "label": {
2095
2100
  "type": "string",
@@ -3003,9 +3008,8 @@ const operationManifest = [
3003
3008
  },
3004
3009
  "url": {
3005
3010
  "type": "string",
3006
- "format": "uri",
3007
3011
  "maxLength": 2048,
3008
- "description": "HTTP(S) link to the external record."
3012
+ "description": "HTTP(S) link to the external record (validated as an `http://` or `https://` URL)."
3009
3013
  },
3010
3014
  "label": {
3011
3015
  "type": "string",
@@ -3195,9 +3199,8 @@ const operationManifest = [
3195
3199
  },
3196
3200
  "url": {
3197
3201
  "type": "string",
3198
- "format": "uri",
3199
3202
  "maxLength": 2048,
3200
- "description": "HTTP(S) link to the external record."
3203
+ "description": "HTTP(S) link to the external record (validated as an `http://` or `https://` URL)."
3201
3204
  },
3202
3205
  "label": {
3203
3206
  "type": "string",
@@ -3213,12 +3216,14 @@ const operationManifest = [
3213
3216
  },
3214
3217
  "run_id": {
3215
3218
  "type": ["string", "null"],
3216
- "maxLength": 128
3219
+ "minLength": 1,
3220
+ "maxLength": 128,
3221
+ "pattern": "^[A-Za-z0-9._:/-]{1,128}$"
3217
3222
  },
3218
3223
  "trace_url": {
3219
3224
  "type": ["string", "null"],
3220
- "format": "uri",
3221
- "maxLength": 2048
3225
+ "maxLength": 2048,
3226
+ "description": "Optional `http://` or `https://` URL linking to an execution trace for this activity."
3222
3227
  },
3223
3228
  "visibility": {
3224
3229
  "type": "string",
@@ -3368,9 +3373,8 @@ const operationManifest = [
3368
3373
  },
3369
3374
  "url": {
3370
3375
  "type": "string",
3371
- "format": "uri",
3372
3376
  "maxLength": 2048,
3373
- "description": "HTTP(S) link to the external record."
3377
+ "description": "HTTP(S) link to the external record (validated as an `http://` or `https://` URL)."
3374
3378
  },
3375
3379
  "label": {
3376
3380
  "type": "string",
@@ -28316,9 +28320,8 @@ const operationManifest = [
28316
28320
  },
28317
28321
  "url": {
28318
28322
  "type": "string",
28319
- "format": "uri",
28320
28323
  "maxLength": 2048,
28321
- "description": "HTTP(S) link to the external record."
28324
+ "description": "HTTP(S) link to the external record (validated as an `http://` or `https://` URL)."
28322
28325
  },
28323
28326
  "label": {
28324
28327
  "type": "string",
@@ -58430,27 +58433,47 @@ async function createAuthenticatedCliApiClient(params) {
58430
58433
  }
58431
58434
  const tokenHolder = userLoginToken;
58432
58435
  const activityHeaders = cliActivityHeadersFromEnv(params.env);
58436
+ const rawFetch = tokenHolder && auth.credentials ? reexchangingFetch({
58437
+ base: params.fetch,
58438
+ reexchange: savedLoginReexchange({
58439
+ apiBaseUrl: auth.apiBaseUrl,
58440
+ configDir: params.configDir,
58441
+ fetch: params.fetch,
58442
+ headers: requestConfig.headers,
58443
+ now: params.now,
58444
+ orgId: auth.credentials.org_id
58445
+ }),
58446
+ token: tokenHolder
58447
+ }) : (input, init) => (params.fetch ?? globalThis.fetch)(input, init);
58448
+ const authenticatedFetch = (async (input, init) => {
58449
+ const activeToken = tokenHolder ? tokenHolder.current : auth.apiKey;
58450
+ const baseHeaders = mergeHeadersCaseInsensitive(auth.connectedAgent || auth.agentPass ? void 0 : requestConfig.headers, cliActivityHeadersFromEnv(params.env), activeToken ? { authorization: `Bearer ${activeToken}` } : void 0);
58451
+ const merged = new Headers(baseHeaders);
58452
+ if (init?.headers) new Headers(init.headers).forEach((value, key) => {
58453
+ if (key.toLowerCase() === "authorization") return;
58454
+ merged.set(key, value);
58455
+ });
58456
+ else if (input instanceof Request) input.headers.forEach((value, key) => {
58457
+ if (key.toLowerCase() === "authorization") return;
58458
+ merged.set(key, value);
58459
+ });
58460
+ return rawFetch(input, {
58461
+ ...init,
58462
+ headers: merged
58463
+ });
58464
+ });
58433
58465
  return {
58434
58466
  apiClient: new PrimitiveApiClient({
58435
58467
  ...tokenHolder && auth.credentials ? {
58436
58468
  auth: (security) => security.type === "http" && security.scheme === "bearer" ? tokenHolder.current : void 0,
58437
- fetch: reexchangingFetch({
58438
- reexchange: savedLoginReexchange({
58439
- apiBaseUrl: auth.apiBaseUrl,
58440
- configDir: params.configDir,
58441
- fetch: params.fetch,
58442
- headers: requestConfig.headers,
58443
- now: params.now,
58444
- orgId: auth.credentials.org_id
58445
- }),
58446
- token: tokenHolder
58447
- })
58469
+ fetch: rawFetch
58448
58470
  } : { apiKey: auth.apiKey },
58449
58471
  apiBaseUrl: auth.apiBaseUrl,
58450
58472
  headers: mergeHeaders(auth.connectedAgent || auth.agentPass ? void 0 : requestConfig.headers, activityHeaders)
58451
58473
  }),
58452
58474
  auth,
58453
58475
  baseUrlOverridden: requestConfig.baseUrlOverridden,
58476
+ fetch: authenticatedFetch,
58454
58477
  requestConfig
58455
58478
  };
58456
58479
  }
@@ -60680,6 +60703,7 @@ async function resolveFocus(params) {
60680
60703
  widen: []
60681
60704
  }
60682
60705
  };
60706
+ if (!asked && params.auth.agentPass) return NO_FOCUS;
60683
60707
  const profile = focusProfile(params.configDir, params.auth);
60684
60708
  const { readable, refusal } = params.readDomains ? {
60685
60709
  readable: await params.readDomains(params.client),
@@ -62575,7 +62599,7 @@ function savedConnectedProfiles(configDir, exclude) {
62575
62599
  */
62576
62600
  async function otherProfiles(configDir, session, current) {
62577
62601
  if (session) try {
62578
- const { connectedProfilesForSession } = await import("./machine-session-BTJXO0vi.js").then((n) => n.s);
62602
+ const { connectedProfilesForSession } = await import("./machine-session-1utuweTi.js").then((n) => n.s);
62579
62603
  return {
62580
62604
  inSession: true,
62581
62605
  profiles: connectedProfilesForSession(configDir, session, current)
@@ -63328,7 +63352,11 @@ function extractErrorCode(payload) {
63328
63352
  if (typeof direct === "string") return direct;
63329
63353
  }
63330
63354
  }
63331
- const ERROR_CODE_HINTS = { [API_ERROR_CODES.unauthorized]: "Hint: run `primitive signin`, pass --api-key explicitly, or set PRIMITIVE_API_KEY in your environment. `primitive whoami` is the fastest way to verify auth is live." };
63355
+ const ERROR_CODE_HINTS = {
63356
+ [API_ERROR_CODES.unauthorized]: "Hint: run `primitive signin`, pass --api-key explicitly, or set PRIMITIVE_API_KEY in your environment. `primitive whoami` is the fastest way to verify auth is live.",
63357
+ access_reason_required: "Hint: this organization requires an access reason on mail requests. Pass --reason \"...\" or set PRIMITIVE_REASON.",
63358
+ activity_header_invalid: "Hint: X-Primitive-Reason must be 1 to 500 printable ASCII characters without newlines; X-Primitive-Run-Id must be 1 to 128 characters matching [A-Za-z0-9._:/-]."
63359
+ };
63332
63360
  const NETWORK_ERROR_HINTS = {
63333
63361
  ENETUNREACH: "Hint: the network is unreachable. If you're behind a proxy and set HTTP(S)_PROXY, re-run with NODE_USE_ENV_PROXY=1 (Node 22+ ignores those env vars by default). `primitive doctor` reports the local environment in one shot.",
63334
63362
  ECONNREFUSED: "Hint: the server refused the connection. Check that your firewall allows egress to *.primitive.dev, that your PRIMITIVE_API_BASE_URL_* overrides (if any) point at a reachable host, and re-run with NODE_USE_ENV_PROXY=1 if you're behind a proxy. `primitive doctor` reports the local environment in one shot.",
@@ -63387,6 +63415,16 @@ function forbiddenHint(payload) {
63387
63415
  if (!permission || record.reason !== "permission_missing") return null;
63388
63416
  return `Hint: This operation needs ${permission}, which this credential does not have. Some operations stay closed to keys and the CLI even with it. Check a credential with \`primitive whoami --check ${permission}\`.`;
63389
63417
  }
63418
+ function agentPassErrorHint(pass, code) {
63419
+ const disconnectCmd = pass.binding.kind === "profile" ? `primitive disconnect --profile ${pass.binding.profile} --local-only` : "primitive disconnect --local-only";
63420
+ if (code === API_ERROR_CODES.unauthorized) {
63421
+ const extendBit = pass.manage_url ? ` Ask the owner to extend it at ${pass.manage_url}?action=extend&add=4h, or` : " Request a fresh pass or";
63422
+ return `Hint: The bound Access Pass "${pass.label}" was rejected (it may have expired or been revoked).${extendBit} run \`${disconnectCmd}\` to clear the local binding.`;
63423
+ }
63424
+ if (code === "key_revoked") return `Hint: The bound Access Pass "${pass.label}" has been revoked. Run \`${disconnectCmd}\` to clear the local binding, or ask the owner for a fresh pass.`;
63425
+ if ((code === "grant_forbidden" || code === API_ERROR_CODES.forbidden) && pass.manage_url) return `Hint: To expand this Access Pass in place, send the owner ${pass.manage_url}?action=expand`;
63426
+ return null;
63427
+ }
63390
63428
  function writeErrorWithHints(payload, response, options = {}) {
63391
63429
  const formatted = formatErrorPayload(payload);
63392
63430
  process.stderr.write(`${formatted}\n`);
@@ -63397,6 +63435,24 @@ function writeErrorWithHints(payload, response, options = {}) {
63397
63435
  return;
63398
63436
  }
63399
63437
  if (!code || options.codeHint === false) return;
63438
+ if (options.auth?.source === "agent-pass" && options.auth.agentPass) {
63439
+ const passHint = agentPassErrorHint(options.auth.agentPass, code);
63440
+ if (code === "grant_forbidden") {
63441
+ process.stderr.write(`${grantForbiddenHint(payload)}\n`);
63442
+ if (passHint) process.stderr.write(`${passHint}\n`);
63443
+ return;
63444
+ }
63445
+ if (code === API_ERROR_CODES.forbidden) {
63446
+ const hint = forbiddenHint(payload);
63447
+ if (hint) process.stderr.write(`${hint}\n`);
63448
+ if (passHint) process.stderr.write(`${passHint}\n`);
63449
+ return;
63450
+ }
63451
+ if (passHint) {
63452
+ process.stderr.write(`${passHint}\n`);
63453
+ return;
63454
+ }
63455
+ }
63400
63456
  if (code === "grant_forbidden") {
63401
63457
  process.stderr.write(`${grantForbiddenHint(payload)}\n`);
63402
63458
  return;
@@ -63999,7 +64055,10 @@ function createOperationCommand(operation) {
63999
64055
  if (result.error) {
64000
64056
  const errorPayload = extractErrorPayload(result.error);
64001
64057
  const operationErrorHint = OPERATION_ERROR_HINTS[operation.sdkName]?.(extractErrorCode(errorPayload), body, errorPayload, collectValues(operation.pathParams, parsedFlags, operation.sdkName), parsedFlags);
64002
- writeErrorWithHints(errorPayload, result.response, { codeHint: !(operationErrorHint && OPERATION_ERROR_HINTS_REPLACING_CODE_HINT.has(operation.sdkName)) });
64058
+ writeErrorWithHints(errorPayload, result.response, {
64059
+ auth,
64060
+ codeHint: !(operationErrorHint && OPERATION_ERROR_HINTS_REPLACING_CODE_HINT.has(operation.sdkName))
64061
+ });
64003
64062
  if (operationErrorHint) process.stderr.write(`${operationErrorHint}\n`);
64004
64063
  if (stepUpUrl) process.stderr.write(approveThenRerunHint(stepUpUrl));
64005
64064
  if (replyStateSurface && isAwaitingRejectedError(errorPayload)) process.stderr.write(`${awaitingRejectedError(replyStateSurface).message}\n`);
@@ -64195,4 +64254,4 @@ function emptyDeliveriesHint(sdkName, query) {
64195
64254
  function canonicalizeCliReferences(description) {
64196
64255
  return canonicalCliText(description).replaceAll("`primitive emails:latest`", "`primitive emails latest`").replaceAll("`primitive describe emails:get-email | jq '.responseSchema.properties'`", "`primitive describe emails:get | jq '.responseSchema.properties'`");
64197
64256
  }
64198
- export { replyInteractionWarning as $, resolveDomainNames as $t, describeWake as A, isBuiltInRoleKey as An, connectNextSteps as At, wakeRecipientField as B, PRIMITIVE_REASON_HEADER as Bn, countFromMeta as Bt, withApproval as C, resolveCliApiRequestConfig as Cn, sendWaitClampNotice as Ct, openBrowser as D, credentialsFromUserLogin as Dn, thrownErrorExitCode as Dt, listenForCopyHotkey as E, RESTRICTED_ROLE_NOTE as En, successfulSendOutcome as Et, sentInThread as F, routeWarningLines as Fn, currentMailSessionKey as Ft, pendingMailPath as G, validateActivityRunId as Gn, focusProfile as Gt, claimPendingMail as H, attachActivityContextFlags as Hn, focusFlagValues as Ht, serverMuted as I, sanitizeForTerminal as In, formatAlreadySentNotice as It, removePendingMail as J, manyDomainsSupported as Jt, readPendingMail as K, joinNames as Kt, serverRelationship as L, shownLine as Ln, FOCUS_ENV as Lt, formatMailWakeLine as M, roleKeyLabel as Mn, generatedAgentName as Mt, latestOwnOutbound as N, roleKeyText as Nn, identitySuggestions as Nt, explainPendingMailNotFound as O, displayedRoleKey as On, DEFAULT_ENROLL_NAME as Ot, readThreadContext as P, switchCurrentOrg as Pn, loadSkillLine as Pt, replyExpectation as Q, readDomainsOrRefusal as Qt, skillFirstLine as R, setKnownCommands as Rn, FOCUS_SERVER_SUPPORT as Rt, terminalApprovalIo as S, refuseOrgSelectionForProfile as Sn, sendOutcomeExitCode as St, formatBrowserLoginInstructions as T, CliOrgRefusedError as Tn, serializeErrorPayload as Tt, clearConsumedPendingMail as U, cliActivityHeadersFromEnv as Un, focusFlags as Ut, wakeRelationship as V, PRIMITIVE_RUN_ID_HEADER as Vn, focusEmptyHint as Vt, clearReadPendingMail as W, validateActivityReason as Wn, focusForCorpus as Wt, interactionNextActions as X, oneDomainAtATimeError as Xt, interactionHumanLine as Y, normalizeDomainNames as Yt, readEmailInteraction as Z, queryScopesItself as Zt, BROWSER_FLAG_DESCRIPTION as _, SAVED_CLI_OAUTH_SESSION_EXPIRED_MESSAGE as _n, formatSendRecordFailureSummary as _t, createOperationCommand as a, withFlagSuggestion as an, assertValidIdempotencyKey as at, approveThenRerunHint as b, mergeHeadersCaseInsensitive as bn, sendErrorMessage as bt, formatErrorPayload as c, readCallerMailFor as cn, checkPriorReplies as ct, networkErrorHint as d, fetchBoundedPages as dn, excludeSignalReplies as dt, resolveFocus as en, wakeInteractionSentence as et, readTextFileFlag as f, withBooleanFlagValues as fn, followUpCommandPrefix as ft, writeErrorWithHints as g, ConnectedAgentKeyRequiredError as gn, formatSendFailureSummary as gt, surfaceUnauthorizedHint as h, withAttachmentWait as hn, formatPriorRepliesWarning as ht, TIME_FLAG_DESCRIPTION as i, writeFocusLine as in, apiResultHttpStatus as it, displayAddress as j, revokeUserLogin as jn, defaultConnectionName as jt, bareAddress as k, fetchCliOrgs as kn, cliInvocation as kt, hasControlCharacter as l, formatFact as ln, classifySendError as lt, runWithTiming as m, ATTACHMENT_WAIT_MAX_MS as mn, formatPriorRepliesCheckSkipped as mt, API_ERROR_CODES as n, withFocusMeta as nn, MAX_SEND_WAIT_TIMEOUT_MS as nt, extractErrorCode as o, emptyEmailListHint as on, buildFollowUpCommand as ot, refusesCredential as p, ATTACHMENT_WAIT_FLAG_DESCRIPTION as pn, formatDeletedEarlierSendNotice as pt, recordPendingMail as q, loadSavedFocus as qt, PAGED_LIMIT_MAX as r, withoutFocus as rn, SEND_OUTCOME_HELP as rt, extractErrorPayload as s, mailReach as sn, buildThrownSendFailureEnvelope as st, API_BASE_URL_FLAG_DESCRIPTION as t, saveFocus as tn, IDEMPOTENCY_KEY_FLAG_DESCRIPTION as tt, isGrantRefusal as u, isEmailId as un, deriveSendIdempotencyKey as ut, STEP_UP_HEADER as v, createAuthenticatedCliApiClient as vn, priorRepliesThatWentOut as vt, canOfferCopyHotkey as w, selectedOrgFromEnv as wn, sentHistoryWindowStart as wt, promptLine as x, refreshStoredCliCredentials as xn, sendIdentityFields as xt, STEP_UP_TOKEN_FLAG_DESCRIPTION as y, createCliApiClient as yn, reportSendCommandResult as yt, wakeReadCommand as z, operationManifest as zn, NO_FOCUS as zt };
64257
+ export { replyExpectation as $, readDomainsOrRefusal as $t, bareAddress as A, fetchCliOrgs as An, cliInvocation as At, wakeReadCommand as B, operationManifest as Bn, NO_FOCUS as Bt, terminalApprovalIo as C, refuseOrgSelectionForProfile as Cn, sendOutcomeExitCode as Ct, listenForCopyHotkey as D, RESTRICTED_ROLE_NOTE as Dn, successfulSendOutcome as Dt, formatBrowserLoginInstructions as E, CliOrgRefusedError as En, serializeErrorPayload as Et, readThreadContext as F, switchCurrentOrg as Fn, loadSkillLine as Ft, clearReadPendingMail as G, validateActivityReason as Gn, focusForCorpus as Gt, wakeRelationship as H, PRIMITIVE_RUN_ID_HEADER as Hn, focusEmptyHint as Ht, sentInThread as I, routeWarningLines as In, currentMailSessionKey as It, recordPendingMail as J, loadSavedFocus as Jt, pendingMailPath as K, validateActivityRunId as Kn, focusProfile as Kt, serverMuted as L, sanitizeForTerminal as Ln, formatAlreadySentNotice as Lt, displayAddress as M, revokeUserLogin as Mn, defaultConnectionName as Mt, formatMailWakeLine as N, roleKeyLabel as Nn, generatedAgentName as Nt, openBrowser as O, credentialsFromUserLogin as On, thrownErrorExitCode as Ot, latestOwnOutbound as P, roleKeyText as Pn, identitySuggestions as Pt, readEmailInteraction as Q, queryScopesItself as Qt, serverRelationship as R, shownLine as Rn, FOCUS_ENV as Rt, promptLine as S, refreshStoredCliCredentials as Sn, sendIdentityFields as St, canOfferCopyHotkey as T, selectedOrgFromEnv as Tn, sentHistoryWindowStart as Tt, claimPendingMail as U, attachActivityContextFlags as Un, focusFlagValues as Ut, wakeRecipientField as V, PRIMITIVE_REASON_HEADER as Vn, countFromMeta as Vt, clearConsumedPendingMail as W, cliActivityHeadersFromEnv as Wn, focusFlags as Wt, interactionHumanLine as X, normalizeDomainNames as Xt, removePendingMail as Y, manyDomainsSupported as Yt, interactionNextActions as Z, oneDomainAtATimeError as Zt, writeErrorWithHints as _, ConnectedAgentKeyRequiredError as _n, formatSendFailureSummary as _t, agentPassErrorHint as a, writeFocusLine as an, apiResultHttpStatus as at, STEP_UP_TOKEN_FLAG_DESCRIPTION as b, createCliApiClient as bn, reportSendCommandResult as bt, extractErrorPayload as c, mailReach as cn, buildThrownSendFailureEnvelope as ct, isGrantRefusal as d, isEmailId as dn, deriveSendIdempotencyKey as dt, resolveDomainNames as en, replyInteractionWarning as et, networkErrorHint as f, fetchBoundedPages as fn, excludeSignalReplies as ft, surfaceUnauthorizedHint as g, withAttachmentWait as gn, formatPriorRepliesWarning as gt, runWithTiming as h, ATTACHMENT_WAIT_MAX_MS as hn, formatPriorRepliesCheckSkipped as ht, TIME_FLAG_DESCRIPTION as i, withoutFocus as in, SEND_OUTCOME_HELP as it, describeWake as j, isBuiltInRoleKey as jn, connectNextSteps as jt, explainPendingMailNotFound as k, displayedRoleKey as kn, DEFAULT_ENROLL_NAME as kt, formatErrorPayload as l, readCallerMailFor as ln, checkPriorReplies as lt, refusesCredential as m, ATTACHMENT_WAIT_FLAG_DESCRIPTION as mn, formatDeletedEarlierSendNotice as mt, API_ERROR_CODES as n, saveFocus as nn, IDEMPOTENCY_KEY_FLAG_DESCRIPTION as nt, createOperationCommand as o, withFlagSuggestion as on, assertValidIdempotencyKey as ot, readTextFileFlag as p, withBooleanFlagValues as pn, followUpCommandPrefix as pt, readPendingMail as q, joinNames as qt, PAGED_LIMIT_MAX as r, withFocusMeta as rn, MAX_SEND_WAIT_TIMEOUT_MS as rt, extractErrorCode as s, emptyEmailListHint as sn, buildFollowUpCommand as st, API_BASE_URL_FLAG_DESCRIPTION as t, resolveFocus as tn, wakeInteractionSentence as tt, hasControlCharacter as u, formatFact as un, classifySendError as ut, BROWSER_FLAG_DESCRIPTION as v, SAVED_CLI_OAUTH_SESSION_EXPIRED_MESSAGE as vn, formatSendRecordFailureSummary as vt, withApproval as w, resolveCliApiRequestConfig as wn, sendWaitClampNotice as wt, approveThenRerunHint as x, mergeHeadersCaseInsensitive as xn, sendErrorMessage as xt, STEP_UP_HEADER as y, createAuthenticatedCliApiClient as yn, priorRepliesThatWentOut as yt, skillFirstLine as z, setKnownCommands as zn, FOCUS_SERVER_SUPPORT as zt };
@@ -49,7 +49,13 @@ const COMMAND_RENAMES = {
49
49
  "account:leave-organization": "roles-and-members:leave",
50
50
  "account:show": "account:get",
51
51
  "account:update-account": "account:update",
52
+ "activity:create-email-activity": "activity:log",
53
+ "activity:create-thread-activity": "activity:log",
54
+ "activity:get-thread-timeline": "activity:timeline",
52
55
  "activity:list-activity-objects": "activity:objects",
56
+ "activity:list-mail-activity-actors": "activity:agents",
57
+ "activity:list-org-mail-activity": "activity:list",
58
+ "activity:update-thread-activity": "activity:update",
53
59
  "address-notes:delete-address-note": "address-notes:delete",
54
60
  "address-notes:get-address-note": "address-notes:get",
55
61
  "address-notes:get-public-address-note": "address-notes:get-public",