happy-imou-cloud 2.1.21 → 2.1.23

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 (26) hide show
  1. package/dist/{BaseReasoningProcessor-DdPnQSmQ.mjs → BaseReasoningProcessor-By0QiYEu.mjs} +2 -2
  2. package/dist/{BaseReasoningProcessor-DxFwO2z9.cjs → BaseReasoningProcessor-_EHQVXKN.cjs} +2 -2
  3. package/dist/{ProviderSelectionHandler-B5Aq5gA_.cjs → ProviderSelectionHandler-BSzm8oJH.cjs} +2 -2
  4. package/dist/{ProviderSelectionHandler-DQITIqZK.mjs → ProviderSelectionHandler-XwkBLKvY.mjs} +2 -2
  5. package/dist/{api-DB30ctmX.mjs → api-CDC4ZRT7.mjs} +73 -16
  6. package/dist/{api-8xtJZeXZ.cjs → api-CusZs0lm.cjs} +75 -15
  7. package/dist/{command-C6injNJE.mjs → command-B7O2Hn-D.mjs} +2 -2
  8. package/dist/{command-79M8Bz4I.cjs → command-Cp_bgCOD.cjs} +2 -2
  9. package/dist/{index-krVv4CWK.mjs → index-CFLvb1x1.mjs} +372 -55
  10. package/dist/{index-D4A092LJ.cjs → index-yX0QThPc.cjs} +374 -57
  11. package/dist/index.cjs +2 -2
  12. package/dist/index.mjs +2 -2
  13. package/dist/lib.cjs +1 -1
  14. package/dist/lib.d.cts +82 -22
  15. package/dist/lib.d.mts +82 -22
  16. package/dist/lib.mjs +1 -1
  17. package/dist/{registerKillSessionHandler-Cl_er9rg.cjs → registerKillSessionHandler-3f8MBSd6.cjs} +2 -2
  18. package/dist/{registerKillSessionHandler-beu2g-Qo.mjs → registerKillSessionHandler-aB2llDD3.mjs} +2 -2
  19. package/dist/{runClaude-DmXinUiz.cjs → runClaude-5moKE082.cjs} +4 -4
  20. package/dist/{runClaude-nzLh-orP.mjs → runClaude-BXO5ycyI.mjs} +4 -4
  21. package/dist/{runCodex-CoqsQ-cb.cjs → runCodex-BJn5KMLg.cjs} +9 -7
  22. package/dist/{runCodex-C-Pjpbxn.mjs → runCodex-DYEMgHdw.mjs} +9 -7
  23. package/dist/{runGemini-CIVm6NWC.mjs → runGemini-CHWnR9gf.mjs} +4 -4
  24. package/dist/{runGemini-BC_5rNMt.cjs → runGemini-CWG0QweX.cjs} +4 -4
  25. package/package.json +1 -1
  26. package/scripts/tooling-utils.mjs +167 -167
package/dist/lib.d.cts CHANGED
@@ -923,24 +923,36 @@ declare const UpdateSchema: z.ZodObject<{
923
923
  message: z.ZodObject<{
924
924
  id: z.ZodString;
925
925
  seq: z.ZodNumber;
926
- content: z.ZodObject<{
927
- c: z.ZodString;
926
+ content: z.ZodUnion<[z.ZodObject<{
928
927
  t: z.ZodLiteral<"encrypted">;
928
+ c: z.ZodString;
929
929
  }, "strip", z.ZodTypeAny, {
930
- c: string;
931
930
  t: "encrypted";
932
- }, {
933
931
  c: string;
932
+ }, {
934
933
  t: "encrypted";
935
- }>;
934
+ c: string;
935
+ }>, z.ZodObject<{
936
+ t: z.ZodLiteral<"plaintext">;
937
+ p: z.ZodString;
938
+ }, "strip", z.ZodTypeAny, {
939
+ t: "plaintext";
940
+ p: string;
941
+ }, {
942
+ t: "plaintext";
943
+ p: string;
944
+ }>]>;
936
945
  localId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
937
946
  createdAt: z.ZodOptional<z.ZodNumber>;
938
947
  updatedAt: z.ZodOptional<z.ZodNumber>;
939
948
  }, "strip", z.ZodTypeAny, {
940
949
  id: string;
941
950
  content: {
942
- c: string;
943
951
  t: "encrypted";
952
+ c: string;
953
+ } | {
954
+ t: "plaintext";
955
+ p: string;
944
956
  };
945
957
  seq: number;
946
958
  createdAt?: number | undefined;
@@ -949,8 +961,11 @@ declare const UpdateSchema: z.ZodObject<{
949
961
  }, {
950
962
  id: string;
951
963
  content: {
952
- c: string;
953
964
  t: "encrypted";
965
+ c: string;
966
+ } | {
967
+ t: "plaintext";
968
+ p: string;
954
969
  };
955
970
  seq: number;
956
971
  createdAt?: number | undefined;
@@ -963,8 +978,11 @@ declare const UpdateSchema: z.ZodObject<{
963
978
  message: {
964
979
  id: string;
965
980
  content: {
966
- c: string;
967
981
  t: "encrypted";
982
+ c: string;
983
+ } | {
984
+ t: "plaintext";
985
+ p: string;
968
986
  };
969
987
  seq: number;
970
988
  createdAt?: number | undefined;
@@ -977,8 +995,11 @@ declare const UpdateSchema: z.ZodObject<{
977
995
  message: {
978
996
  id: string;
979
997
  content: {
980
- c: string;
981
998
  t: "encrypted";
999
+ c: string;
1000
+ } | {
1001
+ t: "plaintext";
1002
+ p: string;
982
1003
  };
983
1004
  seq: number;
984
1005
  createdAt?: number | undefined;
@@ -1162,8 +1183,11 @@ declare const UpdateSchema: z.ZodObject<{
1162
1183
  message: {
1163
1184
  id: string;
1164
1185
  content: {
1165
- c: string;
1166
1186
  t: "encrypted";
1187
+ c: string;
1188
+ } | {
1189
+ t: "plaintext";
1190
+ p: string;
1167
1191
  };
1168
1192
  seq: number;
1169
1193
  createdAt?: number | undefined;
@@ -1238,8 +1262,11 @@ declare const UpdateSchema: z.ZodObject<{
1238
1262
  message: {
1239
1263
  id: string;
1240
1264
  content: {
1241
- c: string;
1242
1265
  t: "encrypted";
1266
+ c: string;
1267
+ } | {
1268
+ t: "plaintext";
1269
+ p: string;
1243
1270
  };
1244
1271
  seq: number;
1245
1272
  createdAt?: number | undefined;
@@ -1447,16 +1474,25 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1447
1474
  id: z.ZodString;
1448
1475
  seq: z.ZodNumber;
1449
1476
  localId: z.ZodNullable<z.ZodString>;
1450
- content: z.ZodObject<{
1451
- c: z.ZodString;
1477
+ content: z.ZodUnion<[z.ZodObject<{
1452
1478
  t: z.ZodLiteral<"encrypted">;
1479
+ c: z.ZodString;
1453
1480
  }, "strip", z.ZodTypeAny, {
1454
- c: string;
1455
1481
  t: "encrypted";
1456
- }, {
1457
1482
  c: string;
1483
+ }, {
1458
1484
  t: "encrypted";
1459
- }>;
1485
+ c: string;
1486
+ }>, z.ZodObject<{
1487
+ t: z.ZodLiteral<"plaintext">;
1488
+ p: z.ZodString;
1489
+ }, "strip", z.ZodTypeAny, {
1490
+ t: "plaintext";
1491
+ p: string;
1492
+ }, {
1493
+ t: "plaintext";
1494
+ p: string;
1495
+ }>]>;
1460
1496
  createdAt: z.ZodNumber;
1461
1497
  updatedAt: z.ZodNumber;
1462
1498
  }, "strip", z.ZodTypeAny, {
@@ -1464,8 +1500,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1464
1500
  createdAt: number;
1465
1501
  updatedAt: number;
1466
1502
  content: {
1467
- c: string;
1468
1503
  t: "encrypted";
1504
+ c: string;
1505
+ } | {
1506
+ t: "plaintext";
1507
+ p: string;
1469
1508
  };
1470
1509
  seq: number;
1471
1510
  localId: string | null;
@@ -1474,8 +1513,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1474
1513
  createdAt: number;
1475
1514
  updatedAt: number;
1476
1515
  content: {
1477
- c: string;
1478
1516
  t: "encrypted";
1517
+ c: string;
1518
+ } | {
1519
+ t: "plaintext";
1520
+ p: string;
1479
1521
  };
1480
1522
  seq: number;
1481
1523
  localId: string | null;
@@ -1488,8 +1530,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1488
1530
  createdAt: number;
1489
1531
  updatedAt: number;
1490
1532
  content: {
1491
- c: string;
1492
1533
  t: "encrypted";
1534
+ c: string;
1535
+ } | {
1536
+ t: "plaintext";
1537
+ p: string;
1493
1538
  };
1494
1539
  seq: number;
1495
1540
  localId: string | null;
@@ -1502,8 +1547,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1502
1547
  createdAt: number;
1503
1548
  updatedAt: number;
1504
1549
  content: {
1505
- c: string;
1506
1550
  t: "encrypted";
1551
+ c: string;
1552
+ } | {
1553
+ t: "plaintext";
1554
+ p: string;
1507
1555
  };
1508
1556
  seq: number;
1509
1557
  localId: string | null;
@@ -1544,8 +1592,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1544
1592
  createdAt: number;
1545
1593
  updatedAt: number;
1546
1594
  content: {
1547
- c: string;
1548
1595
  t: "encrypted";
1596
+ c: string;
1597
+ } | {
1598
+ t: "plaintext";
1599
+ p: string;
1549
1600
  };
1550
1601
  seq: number;
1551
1602
  localId: string | null;
@@ -1586,8 +1637,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1586
1637
  createdAt: number;
1587
1638
  updatedAt: number;
1588
1639
  content: {
1589
- c: string;
1590
1640
  t: "encrypted";
1641
+ c: string;
1642
+ } | {
1643
+ t: "plaintext";
1644
+ p: string;
1591
1645
  };
1592
1646
  seq: number;
1593
1647
  localId: string | null;
@@ -2240,6 +2294,7 @@ type SigningCredentials = {
2240
2294
  type Credentials = {
2241
2295
  token: string;
2242
2296
  signing?: SigningCredentials | null;
2297
+ aesKey?: string;
2243
2298
  encryption: {
2244
2299
  type: 'legacy';
2245
2300
  secret: Uint8Array;
@@ -2421,6 +2476,11 @@ declare class ApiSessionClient extends EventEmitter {
2421
2476
  private waitForPendingBackgroundTasksToDrain;
2422
2477
  private handleSocketUpdate;
2423
2478
  private dispatchEncryptedSessionMessage;
2479
+ /**
2480
+ * Dispatch a plaintext session message (AES mode: server already decrypted).
2481
+ * The plaintext JSON is parsed and validated as a UserMessage.
2482
+ */
2483
+ private dispatchPlaintextSessionMessage;
2424
2484
  private maybeAutoAcknowledgeHappyOrgDispatch;
2425
2485
  private resolveHappyOrgDispatchBusinessAckCandidate;
2426
2486
  private hasRecordedHappyOrgDispatchAck;
package/dist/lib.d.mts CHANGED
@@ -923,24 +923,36 @@ declare const UpdateSchema: z.ZodObject<{
923
923
  message: z.ZodObject<{
924
924
  id: z.ZodString;
925
925
  seq: z.ZodNumber;
926
- content: z.ZodObject<{
927
- c: z.ZodString;
926
+ content: z.ZodUnion<[z.ZodObject<{
928
927
  t: z.ZodLiteral<"encrypted">;
928
+ c: z.ZodString;
929
929
  }, "strip", z.ZodTypeAny, {
930
- c: string;
931
930
  t: "encrypted";
932
- }, {
933
931
  c: string;
932
+ }, {
934
933
  t: "encrypted";
935
- }>;
934
+ c: string;
935
+ }>, z.ZodObject<{
936
+ t: z.ZodLiteral<"plaintext">;
937
+ p: z.ZodString;
938
+ }, "strip", z.ZodTypeAny, {
939
+ t: "plaintext";
940
+ p: string;
941
+ }, {
942
+ t: "plaintext";
943
+ p: string;
944
+ }>]>;
936
945
  localId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
937
946
  createdAt: z.ZodOptional<z.ZodNumber>;
938
947
  updatedAt: z.ZodOptional<z.ZodNumber>;
939
948
  }, "strip", z.ZodTypeAny, {
940
949
  id: string;
941
950
  content: {
942
- c: string;
943
951
  t: "encrypted";
952
+ c: string;
953
+ } | {
954
+ t: "plaintext";
955
+ p: string;
944
956
  };
945
957
  seq: number;
946
958
  createdAt?: number | undefined;
@@ -949,8 +961,11 @@ declare const UpdateSchema: z.ZodObject<{
949
961
  }, {
950
962
  id: string;
951
963
  content: {
952
- c: string;
953
964
  t: "encrypted";
965
+ c: string;
966
+ } | {
967
+ t: "plaintext";
968
+ p: string;
954
969
  };
955
970
  seq: number;
956
971
  createdAt?: number | undefined;
@@ -963,8 +978,11 @@ declare const UpdateSchema: z.ZodObject<{
963
978
  message: {
964
979
  id: string;
965
980
  content: {
966
- c: string;
967
981
  t: "encrypted";
982
+ c: string;
983
+ } | {
984
+ t: "plaintext";
985
+ p: string;
968
986
  };
969
987
  seq: number;
970
988
  createdAt?: number | undefined;
@@ -977,8 +995,11 @@ declare const UpdateSchema: z.ZodObject<{
977
995
  message: {
978
996
  id: string;
979
997
  content: {
980
- c: string;
981
998
  t: "encrypted";
999
+ c: string;
1000
+ } | {
1001
+ t: "plaintext";
1002
+ p: string;
982
1003
  };
983
1004
  seq: number;
984
1005
  createdAt?: number | undefined;
@@ -1162,8 +1183,11 @@ declare const UpdateSchema: z.ZodObject<{
1162
1183
  message: {
1163
1184
  id: string;
1164
1185
  content: {
1165
- c: string;
1166
1186
  t: "encrypted";
1187
+ c: string;
1188
+ } | {
1189
+ t: "plaintext";
1190
+ p: string;
1167
1191
  };
1168
1192
  seq: number;
1169
1193
  createdAt?: number | undefined;
@@ -1238,8 +1262,11 @@ declare const UpdateSchema: z.ZodObject<{
1238
1262
  message: {
1239
1263
  id: string;
1240
1264
  content: {
1241
- c: string;
1242
1265
  t: "encrypted";
1266
+ c: string;
1267
+ } | {
1268
+ t: "plaintext";
1269
+ p: string;
1243
1270
  };
1244
1271
  seq: number;
1245
1272
  createdAt?: number | undefined;
@@ -1447,16 +1474,25 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1447
1474
  id: z.ZodString;
1448
1475
  seq: z.ZodNumber;
1449
1476
  localId: z.ZodNullable<z.ZodString>;
1450
- content: z.ZodObject<{
1451
- c: z.ZodString;
1477
+ content: z.ZodUnion<[z.ZodObject<{
1452
1478
  t: z.ZodLiteral<"encrypted">;
1479
+ c: z.ZodString;
1453
1480
  }, "strip", z.ZodTypeAny, {
1454
- c: string;
1455
1481
  t: "encrypted";
1456
- }, {
1457
1482
  c: string;
1483
+ }, {
1458
1484
  t: "encrypted";
1459
- }>;
1485
+ c: string;
1486
+ }>, z.ZodObject<{
1487
+ t: z.ZodLiteral<"plaintext">;
1488
+ p: z.ZodString;
1489
+ }, "strip", z.ZodTypeAny, {
1490
+ t: "plaintext";
1491
+ p: string;
1492
+ }, {
1493
+ t: "plaintext";
1494
+ p: string;
1495
+ }>]>;
1460
1496
  createdAt: z.ZodNumber;
1461
1497
  updatedAt: z.ZodNumber;
1462
1498
  }, "strip", z.ZodTypeAny, {
@@ -1464,8 +1500,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1464
1500
  createdAt: number;
1465
1501
  updatedAt: number;
1466
1502
  content: {
1467
- c: string;
1468
1503
  t: "encrypted";
1504
+ c: string;
1505
+ } | {
1506
+ t: "plaintext";
1507
+ p: string;
1469
1508
  };
1470
1509
  seq: number;
1471
1510
  localId: string | null;
@@ -1474,8 +1513,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1474
1513
  createdAt: number;
1475
1514
  updatedAt: number;
1476
1515
  content: {
1477
- c: string;
1478
1516
  t: "encrypted";
1517
+ c: string;
1518
+ } | {
1519
+ t: "plaintext";
1520
+ p: string;
1479
1521
  };
1480
1522
  seq: number;
1481
1523
  localId: string | null;
@@ -1488,8 +1530,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1488
1530
  createdAt: number;
1489
1531
  updatedAt: number;
1490
1532
  content: {
1491
- c: string;
1492
1533
  t: "encrypted";
1534
+ c: string;
1535
+ } | {
1536
+ t: "plaintext";
1537
+ p: string;
1493
1538
  };
1494
1539
  seq: number;
1495
1540
  localId: string | null;
@@ -1502,8 +1547,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1502
1547
  createdAt: number;
1503
1548
  updatedAt: number;
1504
1549
  content: {
1505
- c: string;
1506
1550
  t: "encrypted";
1551
+ c: string;
1552
+ } | {
1553
+ t: "plaintext";
1554
+ p: string;
1507
1555
  };
1508
1556
  seq: number;
1509
1557
  localId: string | null;
@@ -1544,8 +1592,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1544
1592
  createdAt: number;
1545
1593
  updatedAt: number;
1546
1594
  content: {
1547
- c: string;
1548
1595
  t: "encrypted";
1596
+ c: string;
1597
+ } | {
1598
+ t: "plaintext";
1599
+ p: string;
1549
1600
  };
1550
1601
  seq: number;
1551
1602
  localId: string | null;
@@ -1586,8 +1637,11 @@ declare const ProtocolV3SessionSnapshotResponseSchema: z.ZodObject<{
1586
1637
  createdAt: number;
1587
1638
  updatedAt: number;
1588
1639
  content: {
1589
- c: string;
1590
1640
  t: "encrypted";
1641
+ c: string;
1642
+ } | {
1643
+ t: "plaintext";
1644
+ p: string;
1591
1645
  };
1592
1646
  seq: number;
1593
1647
  localId: string | null;
@@ -2240,6 +2294,7 @@ type SigningCredentials = {
2240
2294
  type Credentials = {
2241
2295
  token: string;
2242
2296
  signing?: SigningCredentials | null;
2297
+ aesKey?: string;
2243
2298
  encryption: {
2244
2299
  type: 'legacy';
2245
2300
  secret: Uint8Array;
@@ -2421,6 +2476,11 @@ declare class ApiSessionClient extends EventEmitter {
2421
2476
  private waitForPendingBackgroundTasksToDrain;
2422
2477
  private handleSocketUpdate;
2423
2478
  private dispatchEncryptedSessionMessage;
2479
+ /**
2480
+ * Dispatch a plaintext session message (AES mode: server already decrypted).
2481
+ * The plaintext JSON is parsed and validated as a UserMessage.
2482
+ */
2483
+ private dispatchPlaintextSessionMessage;
2424
2484
  private maybeAutoAcknowledgeHappyOrgDispatch;
2425
2485
  private resolveHappyOrgDispatchBusinessAckCandidate;
2426
2486
  private hasRecordedHappyOrgDispatchAck;
package/dist/lib.mjs CHANGED
@@ -1,4 +1,4 @@
1
- export { A as ApiClient, a as ApiSessionClient, c as configuration, l as logger } from './api-DB30ctmX.mjs';
1
+ export { A as ApiClient, a as ApiSessionClient, c as configuration, l as logger } from './api-CDC4ZRT7.mjs';
2
2
  export { R as RawJSONLinesSchema } from './types-CiliQpqS.mjs';
3
3
  import 'axios';
4
4
  import 'chalk';
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
- var index = require('./index-D4A092LJ.cjs');
4
- var persistence = require('./api-8xtJZeXZ.cjs');
3
+ var index = require('./index-yX0QThPc.cjs');
4
+ var persistence = require('./api-CusZs0lm.cjs');
5
5
  var node_crypto = require('node:crypto');
6
6
  var path = require('node:path');
7
7
  var crypto = require('crypto');
@@ -1,5 +1,5 @@
1
- import { k as initialMachineMetadata, R as RuntimeShell, l as resolveCanonicalToolNameV2, f as formatDisplayMessage } from './index-krVv4CWK.mjs';
2
- import { r as readSettings, H as HAPPY_ORG_TURN_REPORT_TAG, d as HAPPY_ORG_SUMMARY_MAX_LENGTH, e as HAPPY_ORG_REPEAT_THRESHOLD, l as logger } from './api-DB30ctmX.mjs';
1
+ import { k as initialMachineMetadata, R as RuntimeShell, l as resolveCanonicalToolNameV2, f as formatDisplayMessage } from './index-CFLvb1x1.mjs';
2
+ import { r as readSettings, H as HAPPY_ORG_TURN_REPORT_TAG, d as HAPPY_ORG_SUMMARY_MAX_LENGTH, e as HAPPY_ORG_REPEAT_THRESHOLD, l as logger } from './api-CDC4ZRT7.mjs';
3
3
  import { randomUUID } from 'node:crypto';
4
4
  import { basename } from 'node:path';
5
5
  import { createHash } from 'crypto';
@@ -1,10 +1,10 @@
1
1
  'use strict';
2
2
 
3
3
  var node_crypto = require('node:crypto');
4
- var persistence = require('./api-8xtJZeXZ.cjs');
4
+ var persistence = require('./api-CusZs0lm.cjs');
5
5
  require('cross-spawn');
6
6
  require('@agentclientprotocol/sdk');
7
- var index = require('./index-D4A092LJ.cjs');
7
+ var index = require('./index-yX0QThPc.cjs');
8
8
  require('ps-list');
9
9
  require('fs');
10
10
  require('path');
@@ -25,9 +25,9 @@ require('tweetnacl');
25
25
  require('open');
26
26
  var React = require('react');
27
27
  var ink = require('ink');
28
- var ProviderSelectionHandler = require('./ProviderSelectionHandler-B5Aq5gA_.cjs');
28
+ var ProviderSelectionHandler = require('./ProviderSelectionHandler-BSzm8oJH.cjs');
29
29
  var types = require('./types-DVk3crez.cjs');
30
- var registerKillSessionHandler = require('./registerKillSessionHandler-Cl_er9rg.cjs');
30
+ var registerKillSessionHandler = require('./registerKillSessionHandler-3f8MBSd6.cjs');
31
31
  require('socket.io-client');
32
32
  require('expo-server-sdk');
33
33
  var node_util = require('node:util');
@@ -1,8 +1,8 @@
1
1
  import { randomUUID } from 'node:crypto';
2
- import { l as logger, f as backoff, g as delay, h as AsyncLock, c as configuration, s as startOfflineReconnection, b as connectionState, A as ApiClient, i as isAuthenticationRequiredError } from './api-DB30ctmX.mjs';
2
+ import { l as logger, f as backoff, g as delay, h as AsyncLock, c as configuration, s as startOfflineReconnection, b as connectionState, A as ApiClient, i as isAuthenticationRequiredError } from './api-CDC4ZRT7.mjs';
3
3
  import 'cross-spawn';
4
4
  import '@agentclientprotocol/sdk';
5
- import { m as getProjectPath, F as Future, n as claudeLocal, E as ExitCodeError, o as trimIdent, q as createClaudeBackend, f as formatDisplayMessage, t as truncateDisplayMessage, u as claudeCheckSession, w as projectPath, x as mapToClaudeMode, P as PushableAsyncIterable, y as query, A as AbortError, e as stopCaffeinate, p as publishSessionRegistration, z as getEnvironmentInfo, a as createSessionMetadata, B as startCaffeinate, b as closeProviderSession } from './index-krVv4CWK.mjs';
5
+ import { m as getProjectPath, F as Future, n as claudeLocal, E as ExitCodeError, o as trimIdent, q as createClaudeBackend, f as formatDisplayMessage, t as truncateDisplayMessage, u as claudeCheckSession, w as projectPath, x as mapToClaudeMode, P as PushableAsyncIterable, y as query, A as AbortError, e as stopCaffeinate, p as publishSessionRegistration, z as getEnvironmentInfo, a as createSessionMetadata, B as startCaffeinate, b as closeProviderSession } from './index-CFLvb1x1.mjs';
6
6
  import 'ps-list';
7
7
  import 'fs';
8
8
  import 'path';
@@ -23,9 +23,9 @@ import 'tweetnacl';
23
23
  import 'open';
24
24
  import React, { useState, useRef, useEffect, useCallback } from 'react';
25
25
  import { useStdout, useInput, Box, Text, render } from 'ink';
26
- import { c as createKeepAliveController, P as ProviderSelectionHandler, r as runModeLoop } from './ProviderSelectionHandler-DQITIqZK.mjs';
26
+ import { c as createKeepAliveController, P as ProviderSelectionHandler, r as runModeLoop } from './ProviderSelectionHandler-XwkBLKvY.mjs';
27
27
  import { R as RawJSONLinesSchema } from './types-CiliQpqS.mjs';
28
- import { B as BasePermissionHandler, d as MessageBuffer, C as ConversationHistory$1, f as buildHappyOrgTurnPrompt, w as waitForResponseCompleteWithAbort, i as finalizeHappyOrgTurnWithBusinessAck, l as launchRuntimeHandleWithFactoryResult, k as forwardAgentMessageToProviderSession, s as syncControlledByUserState, r as resolveHappyOrgQueuedTurn, e as ensureManagedProviderMachine, M as MissingMachineIdError, b as MessageQueue2, h as hashObject, c as registerKillSessionHandler } from './registerKillSessionHandler-beu2g-Qo.mjs';
28
+ import { B as BasePermissionHandler, d as MessageBuffer, C as ConversationHistory$1, f as buildHappyOrgTurnPrompt, w as waitForResponseCompleteWithAbort, i as finalizeHappyOrgTurnWithBusinessAck, l as launchRuntimeHandleWithFactoryResult, k as forwardAgentMessageToProviderSession, s as syncControlledByUserState, r as resolveHappyOrgQueuedTurn, e as ensureManagedProviderMachine, M as MissingMachineIdError, b as MessageQueue2, h as hashObject, c as registerKillSessionHandler } from './registerKillSessionHandler-aB2llDD3.mjs';
29
29
  import 'socket.io-client';
30
30
  import 'expo-server-sdk';
31
31
  import { isDeepStrictEqual } from 'node:util';
@@ -1,8 +1,8 @@
1
1
  'use strict';
2
2
 
3
- var persistence = require('./api-8xtJZeXZ.cjs');
4
- var registerKillSessionHandler = require('./registerKillSessionHandler-Cl_er9rg.cjs');
5
- var index = require('./index-D4A092LJ.cjs');
3
+ var persistence = require('./api-CusZs0lm.cjs');
4
+ var registerKillSessionHandler = require('./registerKillSessionHandler-3f8MBSd6.cjs');
5
+ var index = require('./index-yX0QThPc.cjs');
6
6
  require('cross-spawn');
7
7
  require('@agentclientprotocol/sdk');
8
8
  var node_crypto = require('node:crypto');
@@ -26,8 +26,8 @@ require('tweetnacl');
26
26
  require('open');
27
27
  var React = require('react');
28
28
  var ink = require('ink');
29
- var ProviderSelectionHandler = require('./ProviderSelectionHandler-B5Aq5gA_.cjs');
30
- var BaseReasoningProcessor = require('./BaseReasoningProcessor-DxFwO2z9.cjs');
29
+ var ProviderSelectionHandler = require('./ProviderSelectionHandler-BSzm8oJH.cjs');
30
+ var BaseReasoningProcessor = require('./BaseReasoningProcessor-_EHQVXKN.cjs');
31
31
  require('zod');
32
32
  require('socket.io-client');
33
33
  require('expo-server-sdk');
@@ -1248,8 +1248,10 @@ function resolveIncomingCodexPermissionMode(opts) {
1248
1248
  };
1249
1249
  }
1250
1250
  async function runCodex(opts) {
1251
- const managedSessionTag = index.readManagedSessionTag();
1252
- const sessionTag = managedSessionTag ?? index.resolveManagedSessionTag();
1251
+ const managedSessionTag = opts.startedBy === "daemon" ? index.readManagedSessionTag() : null;
1252
+ const sessionTag = managedSessionTag ?? index.resolveManagedSessionTag(
1253
+ opts.startedBy === "daemon" ? process.env : {}
1254
+ );
1253
1255
  persistence.connectionState.setBackend("Codex");
1254
1256
  const requestedStartingMode = opts.startingMode ?? (opts.startedBy === "daemon" ? "remote" : "local");
1255
1257
  const initialPermissionMode = resolveInitialCodexPermissionMode({
@@ -1,6 +1,6 @@
1
- import { p as preserveSessionRuntimeMetadata, l as logger, b as connectionState, A as ApiClient } from './api-DB30ctmX.mjs';
2
- import { B as BasePermissionHandler, h as hashObject, d as MessageBuffer, C as ConversationHistory$1, f as buildHappyOrgTurnPrompt, w as waitForResponseCompleteWithAbort, i as finalizeHappyOrgTurnWithBusinessAck, c as registerKillSessionHandler, l as launchRuntimeHandleWithFactoryResult, j as inferToolResultError, k as forwardAgentMessageToProviderSession, e as ensureManagedProviderMachine, M as MissingMachineIdError, b as MessageQueue2, r as resolveHappyOrgQueuedTurn, s as syncControlledByUserState } from './registerKillSessionHandler-beu2g-Qo.mjs';
3
- import { f as formatDisplayMessage, v as validateCodexAcpSpawn, h as createCodexBackend, t as truncateDisplayMessage, b as closeProviderSession, e as stopCaffeinate, i as readManagedSessionTag, j as resolveManagedSessionTag } from './index-krVv4CWK.mjs';
1
+ import { p as preserveSessionRuntimeMetadata, l as logger, b as connectionState, A as ApiClient } from './api-CDC4ZRT7.mjs';
2
+ import { B as BasePermissionHandler, h as hashObject, d as MessageBuffer, C as ConversationHistory$1, f as buildHappyOrgTurnPrompt, w as waitForResponseCompleteWithAbort, i as finalizeHappyOrgTurnWithBusinessAck, c as registerKillSessionHandler, l as launchRuntimeHandleWithFactoryResult, j as inferToolResultError, k as forwardAgentMessageToProviderSession, e as ensureManagedProviderMachine, M as MissingMachineIdError, b as MessageQueue2, r as resolveHappyOrgQueuedTurn, s as syncControlledByUserState } from './registerKillSessionHandler-aB2llDD3.mjs';
3
+ import { f as formatDisplayMessage, v as validateCodexAcpSpawn, h as createCodexBackend, t as truncateDisplayMessage, b as closeProviderSession, e as stopCaffeinate, i as readManagedSessionTag, j as resolveManagedSessionTag } from './index-CFLvb1x1.mjs';
4
4
  import 'cross-spawn';
5
5
  import '@agentclientprotocol/sdk';
6
6
  import { randomUUID } from 'node:crypto';
@@ -24,8 +24,8 @@ import 'tweetnacl';
24
24
  import 'open';
25
25
  import React, { useState, useRef, useEffect, useCallback } from 'react';
26
26
  import { useStdout, useInput, Box, Text, render } from 'ink';
27
- import { c as createKeepAliveController, P as ProviderSelectionHandler, r as runModeLoop } from './ProviderSelectionHandler-DQITIqZK.mjs';
28
- import { B as BaseReasoningProcessor, b as bootstrapManagedProviderSession } from './BaseReasoningProcessor-DdPnQSmQ.mjs';
27
+ import { c as createKeepAliveController, P as ProviderSelectionHandler, r as runModeLoop } from './ProviderSelectionHandler-XwkBLKvY.mjs';
28
+ import { B as BaseReasoningProcessor, b as bootstrapManagedProviderSession } from './BaseReasoningProcessor-By0QiYEu.mjs';
29
29
  import 'zod';
30
30
  import 'socket.io-client';
31
31
  import 'expo-server-sdk';
@@ -1246,8 +1246,10 @@ function resolveIncomingCodexPermissionMode(opts) {
1246
1246
  };
1247
1247
  }
1248
1248
  async function runCodex(opts) {
1249
- const managedSessionTag = readManagedSessionTag();
1250
- const sessionTag = managedSessionTag ?? resolveManagedSessionTag();
1249
+ const managedSessionTag = opts.startedBy === "daemon" ? readManagedSessionTag() : null;
1250
+ const sessionTag = managedSessionTag ?? resolveManagedSessionTag(
1251
+ opts.startedBy === "daemon" ? process.env : {}
1252
+ );
1251
1253
  connectionState.setBackend("Codex");
1252
1254
  const requestedStartingMode = opts.startingMode ?? (opts.startedBy === "daemon" ? "remote" : "local");
1253
1255
  const initialPermissionMode = resolveInitialCodexPermissionMode({
@@ -1,10 +1,10 @@
1
1
  import { useStdout, useInput, Box, Text, render } from 'ink';
2
2
  import React, { useState, useRef, useEffect, useCallback } from 'react';
3
3
  import { randomUUID } from 'node:crypto';
4
- import { l as logger, b as connectionState, A as ApiClient } from './api-DB30ctmX.mjs';
5
- import { B as BasePermissionHandler, C as ConversationHistory$1, r as resolveHappyOrgQueuedTurn, e as ensureManagedProviderMachine, M as MissingMachineIdError, s as syncControlledByUserState, b as MessageQueue2, h as hashObject, c as registerKillSessionHandler, d as MessageBuffer, f as buildHappyOrgTurnPrompt, w as waitForResponseCompleteWithAbort, i as finalizeHappyOrgTurnWithBusinessAck, l as launchRuntimeHandleWithFactoryResult, j as inferToolResultError, k as forwardAgentMessageToProviderSession } from './registerKillSessionHandler-beu2g-Qo.mjs';
6
- import { g as getInitialGeminiModel, r as readGeminiLocalConfig, G as GEMINI_MODEL_ENV, b as closeProviderSession, s as saveGeminiModelToConfig, d as createGeminiBackend, e as stopCaffeinate } from './index-krVv4CWK.mjs';
7
- import { B as BaseReasoningProcessor, b as bootstrapManagedProviderSession } from './BaseReasoningProcessor-DdPnQSmQ.mjs';
4
+ import { l as logger, b as connectionState, A as ApiClient } from './api-CDC4ZRT7.mjs';
5
+ import { B as BasePermissionHandler, C as ConversationHistory$1, r as resolveHappyOrgQueuedTurn, e as ensureManagedProviderMachine, M as MissingMachineIdError, s as syncControlledByUserState, b as MessageQueue2, h as hashObject, c as registerKillSessionHandler, d as MessageBuffer, f as buildHappyOrgTurnPrompt, w as waitForResponseCompleteWithAbort, i as finalizeHappyOrgTurnWithBusinessAck, l as launchRuntimeHandleWithFactoryResult, j as inferToolResultError, k as forwardAgentMessageToProviderSession } from './registerKillSessionHandler-aB2llDD3.mjs';
6
+ import { g as getInitialGeminiModel, r as readGeminiLocalConfig, G as GEMINI_MODEL_ENV, b as closeProviderSession, s as saveGeminiModelToConfig, d as createGeminiBackend, e as stopCaffeinate } from './index-CFLvb1x1.mjs';
7
+ import { B as BaseReasoningProcessor, b as bootstrapManagedProviderSession } from './BaseReasoningProcessor-By0QiYEu.mjs';
8
8
  import 'cross-spawn';
9
9
  import '@agentclientprotocol/sdk';
10
10
  import 'ps-list';
@@ -3,10 +3,10 @@
3
3
  var ink = require('ink');
4
4
  var React = require('react');
5
5
  var node_crypto = require('node:crypto');
6
- var persistence = require('./api-8xtJZeXZ.cjs');
7
- var registerKillSessionHandler = require('./registerKillSessionHandler-Cl_er9rg.cjs');
8
- var index = require('./index-D4A092LJ.cjs');
9
- var BaseReasoningProcessor = require('./BaseReasoningProcessor-DxFwO2z9.cjs');
6
+ var persistence = require('./api-CusZs0lm.cjs');
7
+ var registerKillSessionHandler = require('./registerKillSessionHandler-3f8MBSd6.cjs');
8
+ var index = require('./index-yX0QThPc.cjs');
9
+ var BaseReasoningProcessor = require('./BaseReasoningProcessor-_EHQVXKN.cjs');
10
10
  require('cross-spawn');
11
11
  require('@agentclientprotocol/sdk');
12
12
  require('ps-list');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "happy-imou-cloud",
3
- "version": "2.1.21",
3
+ "version": "2.1.23",
4
4
  "description": "hicloud - Imou 企业定制版。关键是 happy!移动端远程 AI 编程工具,支持 Claude Code、Codex 和 Gemini CLI",
5
5
  "author": "long.zhu",
6
6
  "license": "MIT",