@aigne/transport 0.12.4 → 0.13.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,38 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.13.0](https://github.com/AIGNE-io/aigne-framework/compare/transport-v0.12.5...transport-v0.13.0) (2025-08-12)
4
+
5
+
6
+ ### Features
7
+
8
+ * **cli:** add retry functionality and improve error handling for AIGNE Hub ([#348](https://github.com/AIGNE-io/aigne-framework/issues/348)) ([672c93a](https://github.com/AIGNE-io/aigne-framework/commit/672c93abbba8b4b234f6d810536ff4b603a97e1e))
9
+
10
+
11
+ ### Dependencies
12
+
13
+ * The following workspace dependencies were updated
14
+ * dependencies
15
+ * @aigne/openai bumped to 0.11.0
16
+ * devDependencies
17
+ * @aigne/agent-library bumped to 1.21.18
18
+ * @aigne/core bumped to 1.49.0
19
+ * @aigne/default-memory bumped to 1.1.0
20
+ * @aigne/test-utils bumped to 0.5.26
21
+
22
+ ## [0.12.5](https://github.com/AIGNE-io/aigne-framework/compare/transport-v0.12.4...transport-v0.12.5) (2025-08-12)
23
+
24
+
25
+ ### Dependencies
26
+
27
+ * The following workspace dependencies were updated
28
+ * dependencies
29
+ * @aigne/openai bumped to 0.10.17
30
+ * devDependencies
31
+ * @aigne/agent-library bumped to 1.21.17
32
+ * @aigne/core bumped to 1.48.0
33
+ * @aigne/default-memory bumped to 1.0.17
34
+ * @aigne/test-utils bumped to 0.5.25
35
+
3
36
  ## [0.12.4](https://github.com/AIGNE-io/aigne-framework/compare/transport-v0.12.3...transport-v0.12.4) (2025-08-11)
4
37
 
5
38
 
@@ -86,17 +86,22 @@ class BaseClient {
86
86
  if (!result.ok) {
87
87
  let message;
88
88
  let resultText;
89
+ let type;
89
90
  try {
90
91
  const text = await result.text();
91
92
  const json = (0, type_utils_js_1.tryOrThrow)(() => JSON.parse(text));
92
93
  resultText = text;
93
94
  message = json?.error?.message;
95
+ type = json?.error?.type;
94
96
  }
95
97
  catch {
96
98
  // ignore
97
99
  }
98
100
  if (message) {
99
- throw new Error(message);
101
+ const e = new Error(message);
102
+ if (type)
103
+ e.type = type;
104
+ throw e;
100
105
  }
101
106
  throw new Error(`Failed to fetch url ${args[0]} with status ${result.status}: ${resultText}`);
102
107
  }
@@ -83,17 +83,22 @@ export class BaseClient {
83
83
  if (!result.ok) {
84
84
  let message;
85
85
  let resultText;
86
+ let type;
86
87
  try {
87
88
  const text = await result.text();
88
89
  const json = tryOrThrow(() => JSON.parse(text));
89
90
  resultText = text;
90
91
  message = json?.error?.message;
92
+ type = json?.error?.type;
91
93
  }
92
94
  catch {
93
95
  // ignore
94
96
  }
95
97
  if (message) {
96
- throw new Error(message);
98
+ const e = new Error(message);
99
+ if (type)
100
+ e.type = type;
101
+ throw e;
97
102
  }
98
103
  throw new Error(`Failed to fetch url ${args[0]} with status ${result.status}: ${resultText}`);
99
104
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aigne/transport",
3
- "version": "0.12.4",
3
+ "version": "0.13.0",
4
4
  "description": "AIGNE Transport SDK providing HTTP client and server implementations for communication between AIGNE components",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -45,7 +45,7 @@
45
45
  "content-type": "^1.0.5",
46
46
  "raw-body": "^3.0.0",
47
47
  "zod": "^3.25.67",
48
- "@aigne/openai": "^0.10.16"
48
+ "@aigne/openai": "^0.11.0"
49
49
  },
50
50
  "devDependencies": {
51
51
  "@types/bun": "^1.2.18",
@@ -60,10 +60,10 @@
60
60
  "rimraf": "^6.0.1",
61
61
  "typescript": "^5.8.3",
62
62
  "uuid": "^11.1.0",
63
- "@aigne/agent-library": "^1.21.16",
64
- "@aigne/core": "^1.47.0",
65
- "@aigne/test-utils": "^0.5.24",
66
- "@aigne/default-memory": "^1.0.16"
63
+ "@aigne/core": "^1.49.0",
64
+ "@aigne/test-utils": "^0.5.26",
65
+ "@aigne/agent-library": "^1.21.18",
66
+ "@aigne/default-memory": "^1.1.0"
67
67
  },
68
68
  "scripts": {
69
69
  "lint": "tsc --noEmit",