@a2a-js/sdk 0.3.5 → 0.3.7

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/package.json CHANGED
@@ -1,7 +1,8 @@
1
1
  {
2
2
  "name": "@a2a-js/sdk",
3
- "version": "0.3.5",
3
+ "version": "0.3.7",
4
4
  "description": "Server & Client SDK for Agent2Agent protocol",
5
+ "license": "Apache-2.0",
5
6
  "repository": {
6
7
  "type": "git",
7
8
  "url": "git+https://github.com/a2aproject/a2a-js.git"
@@ -40,37 +41,38 @@
40
41
  "README.md"
41
42
  ],
42
43
  "devDependencies": {
43
- "@genkit-ai/googleai": "^1.8.0",
44
- "@genkit-ai/vertexai": "^1.8.0",
45
- "@types/chai": "^5.2.2",
44
+ "@cloudflare/vitest-pool-workers": "^0.10.15",
45
+ "@eslint/js": "^9.39.1",
46
46
  "@types/express": "^5.0.3",
47
- "@types/mocha": "^10.0.10",
48
47
  "@types/node": "^22.13.14",
49
- "@types/sinon": "^17.0.4",
50
48
  "@types/supertest": "^6.0.3",
51
- "c8": "^10.1.3",
52
- "chai": "^5.2.0",
49
+ "@vitest/coverage-v8": "^3.2.4",
50
+ "esbuild": "^0.27.0",
51
+ "eslint": "^9.39.1",
52
+ "eslint-config-prettier": "^10.1.8",
53
+ "eslint-plugin-prettier": "^5.5.4",
53
54
  "express": "^5.1.0",
54
- "genkit": "^1.8.0",
55
55
  "gts": "^6.0.2",
56
56
  "json-schema-to-typescript": "^15.0.4",
57
- "mocha": "^11.6.0",
58
- "sinon": "^20.0.0",
57
+ "prettier": "^3.6.2",
59
58
  "supertest": "^7.1.4",
60
59
  "tsup": "^8.5.0",
61
60
  "tsx": "^4.19.3",
62
- "typescript": "^5.8.2"
61
+ "typescript": "^5.9.3",
62
+ "typescript-eslint": "^8.46.4",
63
+ "vitest": "^3.2.4"
63
64
  },
64
65
  "scripts": {
65
66
  "clean": "gts clean",
66
67
  "build": "tsup",
67
- "pretest": "npm run build",
68
- "test": "mocha test/**/*.spec.ts",
69
- "coverage": "c8 npm run test",
68
+ "test": "vitest run",
69
+ "test:edge": "vitest run --config vitest.edge.config.ts",
70
+ "lint": "tsc --noEmit && npx eslint .",
71
+ "format:readme": "prettier --write ./README.md",
72
+ "lint:fix": "npx eslint . --fix",
73
+ "coverage": "vitest run --coverage",
70
74
  "generate": "curl https://raw.githubusercontent.com/google-a2a/A2A/refs/heads/main/specification/json/a2a.json > spec.json && node scripts/generateTypes.js && rm spec.json",
71
- "a2a:cli": "tsx src/samples/cli.ts",
72
- "agents:movie-agent": "tsx src/samples/agents/movie-agent/index.ts",
73
- "agents:sample-agent": "tsx src/samples/agents/sample-agent/index.ts"
75
+ "test-build": "esbuild ./dist/client/index.js ./dist/server/index.js ./dist/index.js --bundle --platform=neutral --outdir=dist/tmp-checks --outbase=./dist"
74
76
  },
75
77
  "dependencies": {
76
78
  "uuid": "^11.1.0"
@@ -82,8 +84,5 @@
82
84
  "express": {
83
85
  "optional": true
84
86
  }
85
- },
86
- "mocha": {
87
- "require": "tsx"
88
87
  }
89
- }
88
+ }
@@ -1,17 +0,0 @@
1
- import { ac as AgentCard, w as MessageSendParams, B as Message, aw as Task, aO as TaskStatusUpdateEvent, aQ as TaskArtifactUpdateEvent, V as TaskQueryParams, X as TaskIdParams, Z as TaskPushNotificationConfig, a1 as GetTaskPushNotificationConfigParams, a5 as ListTaskPushNotificationConfigParams, a7 as DeleteTaskPushNotificationConfigParams } from './types-DNKcmF0f.js';
2
-
3
- interface A2ARequestHandler {
4
- getAgentCard(): Promise<AgentCard>;
5
- getAuthenticatedExtendedAgentCard(): Promise<AgentCard>;
6
- sendMessage(params: MessageSendParams): Promise<Message | Task>;
7
- sendMessageStream(params: MessageSendParams): AsyncGenerator<Message | Task | TaskStatusUpdateEvent | TaskArtifactUpdateEvent, void, undefined>;
8
- getTask(params: TaskQueryParams): Promise<Task>;
9
- cancelTask(params: TaskIdParams): Promise<Task>;
10
- setTaskPushNotificationConfig(params: TaskPushNotificationConfig): Promise<TaskPushNotificationConfig>;
11
- getTaskPushNotificationConfig(params: TaskIdParams | GetTaskPushNotificationConfigParams): Promise<TaskPushNotificationConfig>;
12
- listTaskPushNotificationConfigs(params: ListTaskPushNotificationConfigParams): Promise<TaskPushNotificationConfig[]>;
13
- deleteTaskPushNotificationConfig(params: DeleteTaskPushNotificationConfigParams): Promise<void>;
14
- resubscribe(params: TaskIdParams): AsyncGenerator<Task | TaskStatusUpdateEvent | TaskArtifactUpdateEvent, void, undefined>;
15
- }
16
-
17
- export type { A2ARequestHandler as A };
@@ -1,17 +0,0 @@
1
- import { ac as AgentCard, w as MessageSendParams, B as Message, aw as Task, aO as TaskStatusUpdateEvent, aQ as TaskArtifactUpdateEvent, V as TaskQueryParams, X as TaskIdParams, Z as TaskPushNotificationConfig, a1 as GetTaskPushNotificationConfigParams, a5 as ListTaskPushNotificationConfigParams, a7 as DeleteTaskPushNotificationConfigParams } from './types-DNKcmF0f.cjs';
2
-
3
- interface A2ARequestHandler {
4
- getAgentCard(): Promise<AgentCard>;
5
- getAuthenticatedExtendedAgentCard(): Promise<AgentCard>;
6
- sendMessage(params: MessageSendParams): Promise<Message | Task>;
7
- sendMessageStream(params: MessageSendParams): AsyncGenerator<Message | Task | TaskStatusUpdateEvent | TaskArtifactUpdateEvent, void, undefined>;
8
- getTask(params: TaskQueryParams): Promise<Task>;
9
- cancelTask(params: TaskIdParams): Promise<Task>;
10
- setTaskPushNotificationConfig(params: TaskPushNotificationConfig): Promise<TaskPushNotificationConfig>;
11
- getTaskPushNotificationConfig(params: TaskIdParams | GetTaskPushNotificationConfigParams): Promise<TaskPushNotificationConfig>;
12
- listTaskPushNotificationConfigs(params: ListTaskPushNotificationConfigParams): Promise<TaskPushNotificationConfig[]>;
13
- deleteTaskPushNotificationConfig(params: DeleteTaskPushNotificationConfigParams): Promise<void>;
14
- resubscribe(params: TaskIdParams): AsyncGenerator<Task | TaskStatusUpdateEvent | TaskArtifactUpdateEvent, void, undefined>;
15
- }
16
-
17
- export type { A2ARequestHandler as A };
@@ -1,6 +0,0 @@
1
- // src/constants.ts
2
- var AGENT_CARD_PATH = ".well-known/agent-card.json";
3
-
4
- export {
5
- AGENT_CARD_PATH
6
- };