@ai-matrx/agents 0.43.18 → 0.43.20

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 (48) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/dist/content-transfer/index.cjs +26 -10
  3. package/dist/content-transfer/index.cjs.map +1 -1
  4. package/dist/content-transfer/index.js +26 -10
  5. package/dist/content-transfer/index.js.map +1 -1
  6. package/dist/content-transfer/react/index.cjs +26 -10
  7. package/dist/content-transfer/react/index.cjs.map +1 -1
  8. package/dist/content-transfer/react/index.js +26 -10
  9. package/dist/content-transfer/react/index.js.map +1 -1
  10. package/dist/generated/api-types.cjs.map +1 -1
  11. package/dist/generated/api-types.d.cts +16 -0
  12. package/dist/generated/api-types.d.ts +16 -0
  13. package/dist/index.cjs +75 -74
  14. package/dist/index.cjs.map +1 -1
  15. package/dist/index.d.cts +1 -1
  16. package/dist/index.d.ts +1 -1
  17. package/dist/index.js +75 -74
  18. package/dist/index.js.map +1 -1
  19. package/dist/{keys.generated-BzkXY1sO.d.cts → keys.generated-BuyboLUH.d.cts} +4 -4
  20. package/dist/{keys.generated-BzkXY1sO.d.ts → keys.generated-BuyboLUH.d.ts} +4 -4
  21. package/dist/mandates/index.cjs +2 -2
  22. package/dist/mandates/index.cjs.map +1 -1
  23. package/dist/mandates/index.d.cts +2 -2
  24. package/dist/mandates/index.d.ts +2 -2
  25. package/dist/mandates/index.js +2 -2
  26. package/dist/mandates/index.js.map +1 -1
  27. package/dist/matrx/index.cjs +75 -74
  28. package/dist/matrx/index.cjs.map +1 -1
  29. package/dist/matrx/index.d.cts +1 -1
  30. package/dist/matrx/index.d.ts +1 -1
  31. package/dist/matrx/index.js +75 -74
  32. package/dist/matrx/index.js.map +1 -1
  33. package/dist/portable/index.cjs +26 -10
  34. package/dist/portable/index.cjs.map +1 -1
  35. package/dist/portable/index.js +26 -10
  36. package/dist/portable/index.js.map +1 -1
  37. package/dist/portable/mcp.cjs +24 -10
  38. package/dist/portable/mcp.cjs.map +1 -1
  39. package/dist/portable/mcp.js +24 -10
  40. package/dist/portable/mcp.js.map +1 -1
  41. package/dist/react/index.cjs +60 -46
  42. package/dist/react/index.cjs.map +1 -1
  43. package/dist/react/index.js +60 -46
  44. package/dist/react/index.js.map +1 -1
  45. package/generated/api-types.ts +16 -0
  46. package/mandates/snapshots/keys.0.43.19.json +653 -0
  47. package/mandates/snapshots/keys.0.43.20.json +653 -0
  48. package/package.json +3 -3
package/dist/index.d.cts CHANGED
@@ -8,7 +8,7 @@ export { ApiTargetLogContext, BackendApiError, BackendApiErrorData, BackendError
8
8
  export { F as FollowRuntimeOperationOptions, a as FollowRuntimeOperationToEndOptions, b as FollowRuntimeOperationToEndResult, M as MatrxAgentStartRequest, c as MatrxCancelResponse, d as MatrxChatMessage, e as MatrxCompletedRun, f as MatrxContextAnchor, g as MatrxConversationContinueRequest, h as MatrxConversationResumeRequest, i as MatrxConversationStart, j as MatrxEphemeralConversation, k as MatrxJsonObject, l as MatrxJsonValue, m as MatrxMandateStartRequest, n as MatrxOperationEventsPage, o as MatrxOperationFollowEvent, p as MatrxOperationStatusResponse, q as MatrxOperationsByLinkResponse, r as MatrxRequestScope, s as MatrxRunError, t as MatrxRunHandle, u as MatrxRuntimeExecutionStatus, v as MatrxRuntimeOperationEvent, w as MatrxRuntimeOperationView, x as MatrxStoredConversationContinue, y as MatrxStoredConversationCreate, z as MatrxStreamCallOptions, A as MatrxTurnFields, R as RunAgentToCompletionOptions, T as TERMINAL_MATRX_RUNTIME_STATUSES, B as cancelAgentRun, C as continueAgentConversation, D as continueEphemeralConversationStart, E as continueStoredConversationStart, G as followRuntimeOperationEvents, H as followRuntimeOperationToEnd, I as getRuntimeOperationStatus, J as getRuntimeOperationsByLink, K as listRuntimeOperationEvents, L as mintMatrxConversationId, N as newEphemeralConversationStart, O as newStoredConversationStart, P as rejoinRuntimeOperation, Q as resumeAgentConversation, S as runAgentToCompletion, U as startAgentRun, V as startMandateRun } from './operations-C9QvBH_2.cjs';
9
9
  import '@ai-matrx/data';
10
10
  import '@ai-matrx/data/net';
11
- import './keys.generated-BzkXY1sO.cjs';
11
+ import './keys.generated-BuyboLUH.cjs';
12
12
 
13
13
  /**
14
14
  * Media reference roles — the builder's side of the one vocabulary.
package/dist/index.d.ts CHANGED
@@ -8,7 +8,7 @@ export { ApiTargetLogContext, BackendApiError, BackendApiErrorData, BackendError
8
8
  export { F as FollowRuntimeOperationOptions, a as FollowRuntimeOperationToEndOptions, b as FollowRuntimeOperationToEndResult, M as MatrxAgentStartRequest, c as MatrxCancelResponse, d as MatrxChatMessage, e as MatrxCompletedRun, f as MatrxContextAnchor, g as MatrxConversationContinueRequest, h as MatrxConversationResumeRequest, i as MatrxConversationStart, j as MatrxEphemeralConversation, k as MatrxJsonObject, l as MatrxJsonValue, m as MatrxMandateStartRequest, n as MatrxOperationEventsPage, o as MatrxOperationFollowEvent, p as MatrxOperationStatusResponse, q as MatrxOperationsByLinkResponse, r as MatrxRequestScope, s as MatrxRunError, t as MatrxRunHandle, u as MatrxRuntimeExecutionStatus, v as MatrxRuntimeOperationEvent, w as MatrxRuntimeOperationView, x as MatrxStoredConversationContinue, y as MatrxStoredConversationCreate, z as MatrxStreamCallOptions, A as MatrxTurnFields, R as RunAgentToCompletionOptions, T as TERMINAL_MATRX_RUNTIME_STATUSES, B as cancelAgentRun, C as continueAgentConversation, D as continueEphemeralConversationStart, E as continueStoredConversationStart, G as followRuntimeOperationEvents, H as followRuntimeOperationToEnd, I as getRuntimeOperationStatus, J as getRuntimeOperationsByLink, K as listRuntimeOperationEvents, L as mintMatrxConversationId, N as newEphemeralConversationStart, O as newStoredConversationStart, P as rejoinRuntimeOperation, Q as resumeAgentConversation, S as runAgentToCompletion, U as startAgentRun, V as startMandateRun } from './operations-C3iHFcnt.js';
9
9
  import '@ai-matrx/data';
10
10
  import '@ai-matrx/data/net';
11
- import './keys.generated-BzkXY1sO.js';
11
+ import './keys.generated-BuyboLUH.js';
12
12
 
13
13
  /**
14
14
  * Media reference roles — the builder's side of the one vocabulary.
package/dist/index.js CHANGED
@@ -787,80 +787,6 @@ function projectWorkflowNodeEvent(current, event) {
787
787
  }
788
788
  }
789
789
 
790
- // matrx/transport.ts
791
- var MatrxApiError = class extends Error {
792
- name = "MatrxApiError";
793
- /** HTTP status of the failed response. */
794
- status;
795
- /** Machine code from the server body (`code`, or `detail.code`), when present. */
796
- code;
797
- /** The parsed server error body, verbatim (undefined when unparsable). */
798
- serverDetail;
799
- /** The request path the failure came from (server-relative). */
800
- path;
801
- constructor(args) {
802
- super(
803
- args.message ?? extractMatrxErrorMessage(args.serverDetail) ?? `HTTP ${args.status}`
804
- );
805
- this.status = args.status;
806
- this.path = args.path;
807
- this.serverDetail = args.serverDetail;
808
- this.code = extractMatrxErrorCode(args.serverDetail);
809
- }
810
- };
811
- function isRecord3(value) {
812
- return typeof value === "object" && value !== null && !Array.isArray(value);
813
- }
814
- function nonBlankString(value) {
815
- return typeof value === "string" && value.trim() ? value : void 0;
816
- }
817
- function extractMatrxErrorMessage(serverDetail) {
818
- if (!isRecord3(serverDetail)) return void 0;
819
- const userMessage = nonBlankString(serverDetail.user_message);
820
- if (userMessage) return userMessage;
821
- const message = nonBlankString(serverDetail.message);
822
- if (message) return message;
823
- if (Array.isArray(serverDetail.details)) {
824
- const messages = serverDetail.details.map((entry) => {
825
- if (!isRecord3(entry)) return void 0;
826
- const detailMessage = nonBlankString(entry.message);
827
- if (!detailMessage) return void 0;
828
- const field = nonBlankString(entry.field);
829
- return field ? `${field}: ${detailMessage}` : detailMessage;
830
- }).filter((m) => typeof m === "string");
831
- if (messages.length > 0) return messages.join("; ");
832
- }
833
- const detail = serverDetail.detail;
834
- if (isRecord3(detail)) {
835
- const detailMessage = nonBlankString(detail.message) ?? nonBlankString(detail.user_message);
836
- if (detailMessage) return detailMessage;
837
- }
838
- if (typeof detail === "string" && detail.trim()) return detail;
839
- if (Array.isArray(detail)) {
840
- const messages = detail.map(
841
- (entry) => isRecord3(entry) ? nonBlankString(entry.msg) : void 0
842
- ).filter((m) => typeof m === "string");
843
- if (messages.length > 0) return messages.join("; ");
844
- }
845
- return void 0;
846
- }
847
- function extractMatrxErrorCode(serverDetail) {
848
- if (!isRecord3(serverDetail)) return null;
849
- const topLevel = nonBlankString(serverDetail.code);
850
- if (topLevel) return topLevel;
851
- const detail = serverDetail.detail;
852
- if (isRecord3(detail)) {
853
- const nested = nonBlankString(detail.code);
854
- if (nested) return nested;
855
- }
856
- return null;
857
- }
858
-
859
- // matrx/client.ts
860
- import { isNetError as isNetError2 } from "@ai-matrx/data";
861
- import { credentialToHeaders } from "@ai-matrx/data";
862
- import { extractErrorMessage } from "@ai-matrx/data/net";
863
-
864
790
  // matrx/backend-errors.ts
865
791
  var BackendApiError = class extends Error {
866
792
  /** Machine-readable error code */
@@ -1166,6 +1092,81 @@ function statusToCode(status) {
1166
1092
  }
1167
1093
  }
1168
1094
 
1095
+ // matrx/transport.ts
1096
+ var MatrxApiError = class extends Error {
1097
+ name = "MatrxApiError";
1098
+ /** HTTP status of the failed response. */
1099
+ status;
1100
+ /** Machine code from the server body (`code`, or `detail.code`), when present. */
1101
+ code;
1102
+ /** The parsed server error body, verbatim (undefined when unparsable). */
1103
+ serverDetail;
1104
+ /** The request path the failure came from (server-relative). */
1105
+ path;
1106
+ constructor(args) {
1107
+ super(
1108
+ args.message ?? extractMatrxErrorMessage(args.serverDetail) ?? `HTTP ${args.status}`
1109
+ );
1110
+ this.status = args.status;
1111
+ this.path = args.path;
1112
+ this.serverDetail = args.serverDetail;
1113
+ this.code = extractMatrxErrorCode(args.serverDetail);
1114
+ }
1115
+ };
1116
+ function isRecord3(value) {
1117
+ return typeof value === "object" && value !== null && !Array.isArray(value);
1118
+ }
1119
+ function nonBlankString(value) {
1120
+ return typeof value === "string" && value.trim() ? value : void 0;
1121
+ }
1122
+ function extractMatrxErrorMessage(serverDetail) {
1123
+ if (!isRecord3(serverDetail)) return void 0;
1124
+ const candidates = [];
1125
+ const push = (value) => {
1126
+ if (value) candidates.push(value);
1127
+ };
1128
+ push(nonBlankString(serverDetail.user_message));
1129
+ push(nonBlankString(serverDetail.message));
1130
+ if (Array.isArray(serverDetail.details)) {
1131
+ const messages = serverDetail.details.map((entry) => {
1132
+ if (!isRecord3(entry)) return void 0;
1133
+ const detailMessage = nonBlankString(entry.message);
1134
+ if (!detailMessage) return void 0;
1135
+ const field = nonBlankString(entry.field);
1136
+ return field ? `${field}: ${detailMessage}` : detailMessage;
1137
+ }).filter((m) => typeof m === "string");
1138
+ if (messages.length > 0) push(messages.join("; "));
1139
+ }
1140
+ const detail = serverDetail.detail;
1141
+ if (isRecord3(detail)) {
1142
+ push(nonBlankString(detail.message) ?? nonBlankString(detail.user_message));
1143
+ }
1144
+ if (typeof detail === "string" && detail.trim()) push(detail);
1145
+ if (Array.isArray(detail)) {
1146
+ const messages = detail.map(
1147
+ (entry) => isRecord3(entry) ? nonBlankString(entry.msg) : void 0
1148
+ ).filter((m) => typeof m === "string");
1149
+ if (messages.length > 0) push(messages.join("; "));
1150
+ }
1151
+ return candidates.find((c) => !isGenericUserMessage(c)) ?? candidates[0];
1152
+ }
1153
+ function extractMatrxErrorCode(serverDetail) {
1154
+ if (!isRecord3(serverDetail)) return null;
1155
+ const topLevel = nonBlankString(serverDetail.code);
1156
+ if (topLevel) return topLevel;
1157
+ const detail = serverDetail.detail;
1158
+ if (isRecord3(detail)) {
1159
+ const nested = nonBlankString(detail.code);
1160
+ if (nested) return nested;
1161
+ }
1162
+ return null;
1163
+ }
1164
+
1165
+ // matrx/client.ts
1166
+ import { isNetError as isNetError2 } from "@ai-matrx/data";
1167
+ import { credentialToHeaders } from "@ai-matrx/data";
1168
+ import { extractErrorMessage } from "@ai-matrx/data/net";
1169
+
1169
1170
  // matrx/org-context.ts
1170
1171
  import { isUuidShape } from "@ai-matrx/kit/uuid";
1171
1172
  var OrganizationContextError = class extends Error {