@vm0/cli 9.142.0 → 9.143.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.
@@ -74083,7 +74083,7 @@ if (DSN) {
74083
74083
  init2({
74084
74084
  dsn: DSN,
74085
74085
  environment: process.env.SENTRY_ENVIRONMENT ?? "production",
74086
- release: "9.142.0",
74086
+ release: "9.143.0",
74087
74087
  sendDefaultPii: false,
74088
74088
  tracesSampleRate: 0,
74089
74089
  shutdownTimeout: 500,
@@ -74102,7 +74102,7 @@ if (DSN) {
74102
74102
  }
74103
74103
  });
74104
74104
  setContext("cli", {
74105
- version: "9.142.0",
74105
+ version: "9.143.0",
74106
74106
  command: process.argv.slice(2).join(" ")
74107
74107
  });
74108
74108
  setContext("runtime", {
@@ -97355,10 +97355,10 @@ var openai = {
97355
97355
  }
97356
97356
  };
97357
97357
 
97358
- // ../../packages/connectors/src/connectors/chatgpt-oauth.ts
97358
+ // ../../packages/connectors/src/connectors/codex-oauth.ts
97359
97359
  init_esm_shims();
97360
- var chatgptOauth = {
97361
- "chatgpt-oauth": {
97360
+ var codexOauth = {
97361
+ "codex-oauth": {
97362
97362
  label: "ChatGPT (OAuth)",
97363
97363
  category: "ai-general-models",
97364
97364
  environmentMapping: {
@@ -100266,7 +100266,7 @@ var CONNECTOR_TYPES_DEF = {
100266
100266
  ...stripe,
100267
100267
  ...onyx,
100268
100268
  ...openai,
100269
- ...chatgptOauth,
100269
+ ...codexOauth,
100270
100270
  ...similarweb,
100271
100271
  ...perplexity,
100272
100272
  ...pipedrive,
@@ -100716,7 +100716,7 @@ var logsListContract = c7.router({
100716
100716
  headers: authHeadersSchema,
100717
100717
  query: listQuerySchema.extend({
100718
100718
  search: external_exports.string().optional(),
100719
- agent: external_exports.string().optional(),
100719
+ agentId: external_exports.string().uuid().optional(),
100720
100720
  name: external_exports.string().optional(),
100721
100721
  since: external_exports.coerce.number().optional(),
100722
100722
  status: logStatusSchema.optional(),
@@ -101350,7 +101350,7 @@ var logsSearchContract = c9.router({
101350
101350
  headers: authHeadersSchema,
101351
101351
  query: external_exports.object({
101352
101352
  keyword: external_exports.string().min(1),
101353
- agent: external_exports.string().optional(),
101353
+ agentId: external_exports.string().uuid().optional(),
101354
101354
  runId: external_exports.string().optional(),
101355
101355
  since: external_exports.coerce.number().optional(),
101356
101356
  limit: external_exports.coerce.number().min(1).max(50).default(20),
@@ -101724,7 +101724,7 @@ var webhookCompleteContract = c11.router({
101724
101724
  var webhookCheckpointsContract = c11.router({
101725
101725
  /**
101726
101726
  * POST /api/webhooks/agent/checkpoints
101727
- * Create checkpoint for completed agent run
101727
+ * Create a recoverable checkpoint for an agent run.
101728
101728
  */
101729
101729
  create: {
101730
101730
  method: "POST",
@@ -102231,7 +102231,7 @@ var zeroLogsSearchContract = c12.router({
102231
102231
  headers: authHeadersSchema,
102232
102232
  query: external_exports.object({
102233
102233
  keyword: external_exports.string().min(1),
102234
- agent: external_exports.string().optional(),
102234
+ agentId: external_exports.string().uuid().optional(),
102235
102235
  runId: external_exports.string().optional(),
102236
102236
  since: external_exports.coerce.number().optional(),
102237
102237
  limit: external_exports.coerce.number().min(1).max(50).default(20),
@@ -102532,14 +102532,33 @@ var MODEL_PROVIDER_TYPES = {
102532
102532
  ],
102533
102533
  defaultModel: "gpt-5.5"
102534
102534
  },
102535
- "chatgpt-oauth-token": {
102535
+ "codex-oauth-token": {
102536
102536
  framework: "codex",
102537
- label: "ChatGPT (Sign in)",
102538
- helpText: "Sign in with ChatGPT (Plus / Pro / Business / Edu / Enterprise). Workspace selection happens on auth.openai.com.",
102537
+ label: "ChatGPT (Codex)",
102538
+ helpText: "Run `codex login` on your machine, then paste the resulting ~/.codex/auth.json contents to authorize ChatGPT (Plus / Pro / Business / Edu / Enterprise) for Codex.",
102539
102539
  authMethods: {
102540
- oauth: {
102541
- label: "Sign in with ChatGPT",
102540
+ // Paste-based auth: client posts CODEX_AUTH_JSON, server parses it via
102541
+ // codex-auth-json-parser.ts and persists the four derived CHATGPT_*
102542
+ // fields. The raw blob is NEVER stored. The wire-shape secret
102543
+ // (CODEX_AUTH_JSON) is declared optional+serverOnly so the contract
102544
+ // accepts it on POST without persisting; the four CHATGPT_* fields are
102545
+ // the canonical stored secrets and the firewall layer reads from those.
102546
+ auth_json: {
102547
+ label: "Codex auth.json",
102548
+ helpText: "Run `codex login` locally, then paste the contents of ~/.codex/auth.json below.",
102542
102549
  secrets: {
102550
+ CODEX_AUTH_JSON: {
102551
+ label: "auth.json contents",
102552
+ required: false,
102553
+ serverOnly: true,
102554
+ placeholder: '{"OPENAI_API_KEY":null,"tokens":{...}}',
102555
+ helpText: "Paste the entire contents of ~/.codex/auth.json"
102556
+ },
102557
+ // CHATGPT_ACCESS_TOKEN and CHATGPT_ACCOUNT_ID reach the sandbox env
102558
+ // as placeholder values (substituted by the firewall token-replacement
102559
+ // layer at egress) — keeping them non-serverOnly preserves the
102560
+ // placeholder injection path. CHATGPT_REFRESH_TOKEN and
102561
+ // CHATGPT_ID_TOKEN stay serverOnly per the #7365 invariant.
102543
102562
  CHATGPT_ACCESS_TOKEN: {
102544
102563
  label: "CHATGPT_ACCESS_TOKEN",
102545
102564
  required: true
@@ -102561,7 +102580,7 @@ var MODEL_PROVIDER_TYPES = {
102561
102580
  }
102562
102581
  }
102563
102582
  },
102564
- defaultAuthMethod: "oauth",
102583
+ defaultAuthMethod: "auth_json",
102565
102584
  environmentMapping: {
102566
102585
  CHATGPT_ACCESS_TOKEN: "$secrets.CHATGPT_ACCESS_TOKEN",
102567
102586
  CHATGPT_ACCOUNT_ID: "$secrets.CHATGPT_ACCOUNT_ID",
@@ -102696,7 +102715,7 @@ function getSelectableProviderTypes() {
102696
102715
  }
102697
102716
  var ANTHROPIC_API_BASE = "https://api.anthropic.com";
102698
102717
  function getFirewallBaseUrl(type) {
102699
- if (type === "chatgpt-oauth-token") {
102718
+ if (type === "codex-oauth-token") {
102700
102719
  return "https://chatgpt.com/backend-api/codex";
102701
102720
  }
102702
102721
  if (getFrameworkForType(type) === "codex") {
@@ -102805,8 +102824,8 @@ var MODEL_PROVIDER_FIREWALL_CONFIGS = {
102805
102824
  // here only needs to be a stable, non-empty string the firewall can match
102806
102825
  // and substitute. Account-id placeholder still equals #11877's literal
102807
102826
  // since the architectural relationship across the two surfaces matters.
102808
- "chatgpt-oauth-token": {
102809
- name: "model-provider:chatgpt-oauth-token",
102827
+ "codex-oauth-token": {
102828
+ name: "model-provider:codex-oauth-token",
102810
102829
  apis: [
102811
102830
  {
102812
102831
  base: "https://chatgpt.com/backend-api/codex",
@@ -102844,7 +102863,7 @@ var modelProviderTypeSchema = external_exports.enum([
102844
102863
  "zai-api-key",
102845
102864
  "vercel-ai-gateway",
102846
102865
  "openai-api-key",
102847
- "chatgpt-oauth-token",
102866
+ "codex-oauth-token",
102848
102867
  "azure-foundry",
102849
102868
  "aws-bedrock",
102850
102869
  "vm0"
@@ -102913,9 +102932,9 @@ var modelProviderResponseSchema = external_exports.object({
102913
102932
  selectedModel: external_exports.string().nullable(),
102914
102933
  createdAt: external_exports.string(),
102915
102934
  updatedAt: external_exports.string(),
102916
- // ChatGPT-only metadata populated by the chatgpt-oauth-token callback.
102935
+ // ChatGPT-only metadata populated by the codex-oauth-token callback.
102917
102936
  // Other provider types omit these. Mirrors the server-side connector
102918
- // shape in apps/web/src/lib/zero/connector/providers/chatgpt-oauth.ts.
102937
+ // shape in apps/web/src/lib/zero/connector/providers/codex-oauth.ts.
102919
102938
  // The corresponding server route lands in #11909; declared here so the
102920
102939
  // platform UI does not have to bypass schema validation to read them.
102921
102940
  workspaceName: external_exports.string().nullable().optional(),
@@ -102987,6 +103006,21 @@ var persistedAttachmentSchema = external_exports.object({
102987
103006
  contentType: external_exports.string(),
102988
103007
  size: external_exports.number()
102989
103008
  });
103009
+ var pendingMessageSchema = external_exports.object({
103010
+ content: external_exports.string().nullable(),
103011
+ attachments: external_exports.array(persistedAttachmentSchema).nullable(),
103012
+ createdAt: external_exports.string(),
103013
+ updatedAt: external_exports.string()
103014
+ });
103015
+ var appendPendingMessageBodySchema = external_exports.object({
103016
+ content: external_exports.string().min(1).optional(),
103017
+ attachments: external_exports.array(persistedAttachmentSchema).min(1).optional()
103018
+ }).refine(
103019
+ (body) => {
103020
+ return body.content !== void 0 || body.attachments !== void 0;
103021
+ },
103022
+ { message: "content or attachments is required" }
103023
+ );
102990
103024
  var chatThreadListItemSchema = external_exports.object({
102991
103025
  id: external_exports.string(),
102992
103026
  title: external_exports.string().nullable(),
@@ -103086,6 +103120,7 @@ var chatThreadDetailSchema = external_exports.object({
103086
103120
  updatedAt: external_exports.string(),
103087
103121
  draftContent: external_exports.string().nullable().optional(),
103088
103122
  draftAttachments: external_exports.array(persistedAttachmentSchema).nullable().optional(),
103123
+ pendingMessage: pendingMessageSchema.nullable().optional(),
103089
103124
  /**
103090
103125
  * Per-thread model override. Both fields set together or both null.
103091
103126
  * When set, the send route uses this combination (overriding the agent
@@ -103246,6 +103281,56 @@ var chatThreadRenameContract = c13.router({
103246
103281
  summary: "Rename a chat thread (suppresses automated title generation)"
103247
103282
  }
103248
103283
  });
103284
+ var chatThreadPendingMessageAppendContract = c13.router({
103285
+ append: {
103286
+ method: "POST",
103287
+ path: "/api/zero/chat-threads/:id/pending-message/append",
103288
+ headers: authHeadersSchema,
103289
+ pathParams: external_exports.object({ id: external_exports.string() }),
103290
+ body: appendPendingMessageBodySchema,
103291
+ responses: {
103292
+ 200: external_exports.object({ pendingMessage: pendingMessageSchema }),
103293
+ 400: apiErrorSchema,
103294
+ 401: apiErrorSchema,
103295
+ 404: apiErrorSchema
103296
+ },
103297
+ summary: "Append submitted content to a chat thread pending message"
103298
+ }
103299
+ });
103300
+ var chatThreadPendingMessageDeleteContract = c13.router({
103301
+ delete: {
103302
+ method: "DELETE",
103303
+ path: "/api/zero/chat-threads/:id/pending-message",
103304
+ headers: authHeadersSchema,
103305
+ pathParams: external_exports.object({ id: external_exports.string() }),
103306
+ body: c13.noBody(),
103307
+ responses: {
103308
+ 204: c13.noBody(),
103309
+ 401: apiErrorSchema,
103310
+ 404: apiErrorSchema
103311
+ },
103312
+ summary: "Discard a chat thread pending message"
103313
+ }
103314
+ });
103315
+ var chatThreadPendingMessageRecallContract = c13.router({
103316
+ recall: {
103317
+ method: "POST",
103318
+ path: "/api/zero/chat-threads/:id/pending-message/recall",
103319
+ headers: authHeadersSchema,
103320
+ pathParams: external_exports.object({ id: external_exports.string() }),
103321
+ body: c13.noBody(),
103322
+ responses: {
103323
+ 200: external_exports.object({
103324
+ draftContent: external_exports.string().nullable(),
103325
+ draftAttachments: external_exports.array(persistedAttachmentSchema).nullable(),
103326
+ pendingMessage: external_exports.null()
103327
+ }),
103328
+ 401: apiErrorSchema,
103329
+ 404: apiErrorSchema
103330
+ },
103331
+ summary: "Recall a chat thread pending message back into the draft"
103332
+ }
103333
+ });
103249
103334
  var chatMessagesContract = c13.router({
103250
103335
  send: {
103251
103336
  method: "POST",
@@ -103323,7 +103408,7 @@ var chatSearchContract = c13.router({
103323
103408
  headers: authHeadersSchema,
103324
103409
  query: external_exports.object({
103325
103410
  keyword: external_exports.string().min(1),
103326
- agent: external_exports.string().optional(),
103411
+ agentId: external_exports.string().uuid().optional(),
103327
103412
  since: external_exports.coerce.number().optional(),
103328
103413
  limit: external_exports.coerce.number().min(1).max(50).default(20),
103329
103414
  before: external_exports.coerce.number().min(0).max(10).default(0),
@@ -103418,7 +103503,7 @@ async function searchZeroChat(options) {
103418
103503
  const result = await client.search({
103419
103504
  query: {
103420
103505
  keyword: options.keyword,
103421
- agent: options.agent,
103506
+ agentId: options.agentId,
103422
103507
  since: options.since,
103423
103508
  limit: options.limit,
103424
103509
  before: options.before,
@@ -103501,7 +103586,7 @@ async function searchLogs(options) {
103501
103586
  const result = await client.searchLogs({
103502
103587
  query: {
103503
103588
  keyword: options.keyword,
103504
- agent: options.agent,
103589
+ agentId: options.agentId,
103505
103590
  runId: options.runId,
103506
103591
  since: options.since,
103507
103592
  limit: options.limit,
@@ -104403,7 +104488,7 @@ init_esm_shims();
104403
104488
  async function listSkills() {
104404
104489
  const config4 = await getClientConfig();
104405
104490
  const client = initClient(zeroSkillsCollectionContract, config4);
104406
- const result = await client.list();
104491
+ const result = await client.list({ headers: {} });
104407
104492
  if (result.status === 200) return result.body;
104408
104493
  handleError(result, "Failed to list skills");
104409
104494
  }
@@ -105131,7 +105216,7 @@ async function listZeroLogs(options) {
105131
105216
  const client = initClient(logsListContract, config4);
105132
105217
  const result = await client.list({
105133
105218
  query: {
105134
- agent: options?.agent,
105219
+ agentId: options?.agentId,
105135
105220
  status: options?.status,
105136
105221
  since: options?.since,
105137
105222
  limit: options?.limit,
@@ -105147,7 +105232,7 @@ async function searchZeroLogs(options) {
105147
105232
  const result = await client.searchLogs({
105148
105233
  query: {
105149
105234
  keyword: options.keyword,
105150
- agent: options.agent,
105235
+ agentId: options.agentId,
105151
105236
  runId: options.runId,
105152
105237
  since: options.since,
105153
105238
  limit: options.limit,
@@ -105243,7 +105328,7 @@ async function unregisterComputerUseHost() {
105243
105328
  async function getComputerUseHost() {
105244
105329
  const config4 = await getClientConfig();
105245
105330
  const client = initClient(zeroComputerUseHostContract, config4);
105246
- const result = await client.getHost({});
105331
+ const result = await client.getHost({ headers: {} });
105247
105332
  if (result.status === 200) {
105248
105333
  return result.body;
105249
105334
  }
@@ -120307,6 +120392,11 @@ var FEATURE_SWITCHES = {
120307
120392
  description: "Show an icon button in assistant message group actions that scrolls back to the start of that message group.",
120308
120393
  enabled: false
120309
120394
  },
120395
+ ["queueMessage" /* QueueMessage */]: {
120396
+ maintainer: "linghan@vm0.ai",
120397
+ description: "Allow keyboard sends during an active chat thread run to append the draft to that thread's pending message queue.",
120398
+ enabled: false
120399
+ },
120310
120400
  ["chatThreadPin" /* ChatThreadPin */]: {
120311
120401
  maintainer: "ethan@vm0.ai",
120312
120402
  description: "Replace the sidebar's per-thread trash button with a kebab/pin menu that exposes Pin/Unpin and Delete. Pinned threads sort to the top of the agent's chat list. Mobile shows the menu trigger always; desktop shows it on hover.",
@@ -120370,7 +120460,7 @@ var FEATURE_SWITCHES = {
120370
120460
  enabled: false,
120371
120461
  enabledOrgIdHashes: STAFF_ORG_ID_HASHES
120372
120462
  },
120373
- ["chatgptOauthProvider" /* ChatgptOauthProvider */]: {
120463
+ ["codexOauthProvider" /* CodexOauthProvider */]: {
120374
120464
  maintainer: "lancy@vm0.ai",
120375
120465
  description: "Gate the ChatGPT-OAuth model provider in zero web (Epic #11872). When off, the 'Connect ChatGPT' tile is hidden in the add-provider dialog, server routes that initiate the OAuth dance return 404, and stale-provider UX is bypassed. Staff-only during rollout; per-user toggle via Lab.",
120376
120466
  enabled: false,
@@ -121760,4 +121850,4 @@ undici/lib/web/fetch/body.js:
121760
121850
  undici/lib/web/websocket/frame.js:
121761
121851
  (*! ws. MIT License. Einar Otto Stangvik <einaros@gmail.com> *)
121762
121852
  */
121763
- //# sourceMappingURL=chunk-OD6W3UMZ.js.map
121853
+ //# sourceMappingURL=chunk-FEQSPUBX.js.map