@a2a-js/sdk 0.3.4 → 0.3.6

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.
@@ -2559,4 +2559,31 @@ interface TaskStatus2 {
2559
2559
  timestamp?: string;
2560
2560
  }
2561
2561
 
2562
- export type { GetTaskPushNotificationConfigRequest as $, A2AError as A, Message as B, CancelTaskResponse as C, DeleteTaskPushNotificationConfigSuccessResponse as D, TextPart as E, FilePart as F, GetTaskResponse as G, FileWithBytes as H, InvalidRequestError as I, JSONRPCErrorResponse as J, FileWithUri as K, ListTaskPushNotificationConfigSuccessResponse as L, MySchema as M, DataPart as N, SendStreamingMessageRequest as O, Part as P, MessageSendParams1 as Q, GetTaskRequest as R, SendMessageResponse as S, TaskState as T, UnsupportedOperationError as U, TaskQueryParams as V, CancelTaskRequest as W, TaskIdParams as X, SetTaskPushNotificationConfigRequest as Y, TaskPushNotificationConfig as Z, PushNotificationConfig1 as _, SendStreamingMessageResponse as a, PasswordOAuthFlow1 as a$, TaskIdParams1 as a0, GetTaskPushNotificationConfigParams as a1, TaskResubscriptionRequest as a2, TaskIdParams2 as a3, ListTaskPushNotificationConfigRequest as a4, ListTaskPushNotificationConfigParams as a5, DeleteTaskPushNotificationConfigRequest as a6, DeleteTaskPushNotificationConfigParams as a7, GetAuthenticatedExtendedCardRequest as a8, APIKeySecurityScheme as a9, ClientCredentialsOAuthFlow1 as aA, DeleteTaskPushNotificationConfigParams1 as aB, FileBase as aC, AgentCard1 as aD, GetTaskPushNotificationConfigSuccessResponse as aE, TaskPushNotificationConfig1 as aF, GetTaskSuccessResponse as aG, Task1 as aH, ImplicitOAuthFlow1 as aI, JSONRPCMessage as aJ, JSONRPCRequest as aK, SendMessageSuccessResponse as aL, Task2 as aM, SendStreamingMessageSuccessResponse as aN, TaskStatusUpdateEvent as aO, TaskStatus1 as aP, TaskArtifactUpdateEvent as aQ, Artifact1 as aR, SetTaskPushNotificationConfigSuccessResponse as aS, TaskPushNotificationConfig2 as aT, TaskPushNotificationConfig3 as aU, JSONRPCSuccessResponse as aV, ListTaskPushNotificationConfigParams1 as aW, MessageSendConfiguration1 as aX, MessageSendParams2 as aY, OAuthFlows1 as aZ, PartBase as a_, AgentCapabilities as aa, AgentExtension as ab, AgentCard as ac, AgentInterface as ad, AgentCapabilities1 as ae, AgentProvider as af, HTTPAuthSecurityScheme as ag, OAuth2SecurityScheme as ah, OAuthFlows as ai, AuthorizationCodeOAuthFlow as aj, ClientCredentialsOAuthFlow as ak, ImplicitOAuthFlow as al, PasswordOAuthFlow as am, OpenIdConnectSecurityScheme as an, MutualTLSSecurityScheme as ao, AgentCardSignature as ap, AgentSkill as aq, AgentProvider1 as ar, Artifact as as, AuthorizationCodeOAuthFlow1 as at, JSONRPCError as au, CancelTaskSuccessResponse as av, Task as aw, Message1 as ax, TaskStatus as ay, Message2 as az, SetTaskPushNotificationConfigResponse as b, PushNotificationAuthenticationInfo1 as b0, PushNotificationConfig2 as b1, SecuritySchemeBase as b2, TaskQueryParams1 as b3, TaskStatus2 as b4, GetTaskPushNotificationConfigResponse as c, GetAuthenticatedExtendedCardSuccessResponse as d, A2ARequest as e, SecurityScheme as f, DeleteTaskPushNotificationConfigResponse as g, GetAuthenticatedExtendedCardResponse as h, JSONRPCResponse as i, ListTaskPushNotificationConfigResponse as j, TransportProtocol as k, JSONParseError as l, MethodNotFoundError as m, InvalidParamsError as n, InternalError as o, TaskNotFoundError as p, TaskNotCancelableError as q, PushNotificationNotSupportedError as r, ContentTypeNotSupportedError as s, InvalidAgentResponseError as t, AuthenticatedExtendedCardNotConfiguredError as u, SendMessageRequest as v, MessageSendParams as w, MessageSendConfiguration as x, PushNotificationConfig as y, PushNotificationAuthenticationInfo as z };
2562
+ /**
2563
+ * A2A Protocol Extension URI.
2564
+ */
2565
+ type ExtensionURI = string;
2566
+ /**
2567
+ * A collection of {@link ExtensionURI}.
2568
+ */
2569
+ type Extensions = ExtensionURI[];
2570
+ declare const Extensions: {
2571
+ /**
2572
+ * Creates new {@link Extensions} from `current` and `additional`.
2573
+ * If `current` already contains `additional` it is returned unmodified.
2574
+ */
2575
+ createFrom: (current: Extensions | undefined, additional: ExtensionURI) => Extensions;
2576
+ /**
2577
+ * Creates {@link Extensions} from comma separated extensions identifiers as per
2578
+ * https://a2a-protocol.org/latest/specification/#326-service-parameters.
2579
+ * Parses the output of `toServiceParameter`.
2580
+ */
2581
+ parseServiceParameter: (value: string | undefined) => Extensions;
2582
+ /**
2583
+ * Converts {@link Extensions} to comma separated extensions identifiers as per
2584
+ * https://a2a-protocol.org/latest/specification/#326-service-parameters.
2585
+ */
2586
+ toServiceParameter: (value: Extensions) => string;
2587
+ };
2588
+
2589
+ export { type TaskPushNotificationConfig as $, type A2AError as A, type PushNotificationAuthenticationInfo as B, type CancelTaskResponse as C, type DeleteTaskPushNotificationConfigSuccessResponse as D, Extensions as E, type Message as F, type GetTaskResponse as G, type TextPart as H, type InvalidRequestError as I, type JSONRPCErrorResponse as J, type FilePart as K, type ListTaskPushNotificationConfigSuccessResponse as L, type MySchema as M, type FileWithBytes as N, type FileWithUri as O, type Part as P, type DataPart as Q, type SendStreamingMessageRequest as R, type SendMessageResponse as S, type TaskState as T, type UnsupportedOperationError as U, type MessageSendParams1 as V, type GetTaskRequest as W, type TaskQueryParams as X, type CancelTaskRequest as Y, type TaskIdParams as Z, type SetTaskPushNotificationConfigRequest as _, type SendStreamingMessageResponse as a, type OAuthFlows1 as a$, type PushNotificationConfig1 as a0, type GetTaskPushNotificationConfigRequest as a1, type TaskIdParams1 as a2, type GetTaskPushNotificationConfigParams as a3, type TaskResubscriptionRequest as a4, type TaskIdParams2 as a5, type ListTaskPushNotificationConfigRequest as a6, type ListTaskPushNotificationConfigParams as a7, type DeleteTaskPushNotificationConfigRequest as a8, type DeleteTaskPushNotificationConfigParams as a9, type TaskStatus as aA, type Message2 as aB, type ClientCredentialsOAuthFlow1 as aC, type DeleteTaskPushNotificationConfigParams1 as aD, type FileBase as aE, type AgentCard1 as aF, type GetTaskPushNotificationConfigSuccessResponse as aG, type TaskPushNotificationConfig1 as aH, type GetTaskSuccessResponse as aI, type Task1 as aJ, type ImplicitOAuthFlow1 as aK, type JSONRPCMessage as aL, type JSONRPCRequest as aM, type SendMessageSuccessResponse as aN, type Task2 as aO, type SendStreamingMessageSuccessResponse as aP, type TaskStatusUpdateEvent as aQ, type TaskStatus1 as aR, type TaskArtifactUpdateEvent as aS, type Artifact1 as aT, type SetTaskPushNotificationConfigSuccessResponse as aU, type TaskPushNotificationConfig2 as aV, type TaskPushNotificationConfig3 as aW, type JSONRPCSuccessResponse as aX, type ListTaskPushNotificationConfigParams1 as aY, type MessageSendConfiguration1 as aZ, type MessageSendParams2 as a_, type GetAuthenticatedExtendedCardRequest as aa, type APIKeySecurityScheme as ab, type AgentCapabilities as ac, type AgentExtension as ad, type AgentCard as ae, type AgentInterface as af, type AgentCapabilities1 as ag, type AgentProvider as ah, type HTTPAuthSecurityScheme as ai, type OAuth2SecurityScheme as aj, type OAuthFlows as ak, type AuthorizationCodeOAuthFlow as al, type ClientCredentialsOAuthFlow as am, type ImplicitOAuthFlow as an, type PasswordOAuthFlow as ao, type OpenIdConnectSecurityScheme as ap, type MutualTLSSecurityScheme as aq, type AgentCardSignature as ar, type AgentSkill as as, type AgentProvider1 as at, type Artifact as au, type AuthorizationCodeOAuthFlow1 as av, type JSONRPCError as aw, type CancelTaskSuccessResponse as ax, type Task as ay, type Message1 as az, type SetTaskPushNotificationConfigResponse as b, type PartBase as b0, type PasswordOAuthFlow1 as b1, type PushNotificationAuthenticationInfo1 as b2, type PushNotificationConfig2 as b3, type SecuritySchemeBase as b4, type TaskQueryParams1 as b5, type TaskStatus2 as b6, type GetTaskPushNotificationConfigResponse as c, type GetAuthenticatedExtendedCardSuccessResponse as d, type ExtensionURI as e, type A2ARequest as f, type SecurityScheme as g, type DeleteTaskPushNotificationConfigResponse as h, type GetAuthenticatedExtendedCardResponse as i, type JSONRPCResponse as j, type ListTaskPushNotificationConfigResponse as k, type TransportProtocol as l, type JSONParseError as m, type MethodNotFoundError as n, type InvalidParamsError as o, type InternalError as p, type TaskNotFoundError as q, type TaskNotCancelableError as r, type PushNotificationNotSupportedError as s, type ContentTypeNotSupportedError as t, type InvalidAgentResponseError as u, type AuthenticatedExtendedCardNotConfiguredError as v, type SendMessageRequest as w, type MessageSendParams as x, type MessageSendConfiguration as y, type PushNotificationConfig as z };
@@ -2559,4 +2559,31 @@ interface TaskStatus2 {
2559
2559
  timestamp?: string;
2560
2560
  }
2561
2561
 
2562
- export type { GetTaskPushNotificationConfigRequest as $, A2AError as A, Message as B, CancelTaskResponse as C, DeleteTaskPushNotificationConfigSuccessResponse as D, TextPart as E, FilePart as F, GetTaskResponse as G, FileWithBytes as H, InvalidRequestError as I, JSONRPCErrorResponse as J, FileWithUri as K, ListTaskPushNotificationConfigSuccessResponse as L, MySchema as M, DataPart as N, SendStreamingMessageRequest as O, Part as P, MessageSendParams1 as Q, GetTaskRequest as R, SendMessageResponse as S, TaskState as T, UnsupportedOperationError as U, TaskQueryParams as V, CancelTaskRequest as W, TaskIdParams as X, SetTaskPushNotificationConfigRequest as Y, TaskPushNotificationConfig as Z, PushNotificationConfig1 as _, SendStreamingMessageResponse as a, PasswordOAuthFlow1 as a$, TaskIdParams1 as a0, GetTaskPushNotificationConfigParams as a1, TaskResubscriptionRequest as a2, TaskIdParams2 as a3, ListTaskPushNotificationConfigRequest as a4, ListTaskPushNotificationConfigParams as a5, DeleteTaskPushNotificationConfigRequest as a6, DeleteTaskPushNotificationConfigParams as a7, GetAuthenticatedExtendedCardRequest as a8, APIKeySecurityScheme as a9, ClientCredentialsOAuthFlow1 as aA, DeleteTaskPushNotificationConfigParams1 as aB, FileBase as aC, AgentCard1 as aD, GetTaskPushNotificationConfigSuccessResponse as aE, TaskPushNotificationConfig1 as aF, GetTaskSuccessResponse as aG, Task1 as aH, ImplicitOAuthFlow1 as aI, JSONRPCMessage as aJ, JSONRPCRequest as aK, SendMessageSuccessResponse as aL, Task2 as aM, SendStreamingMessageSuccessResponse as aN, TaskStatusUpdateEvent as aO, TaskStatus1 as aP, TaskArtifactUpdateEvent as aQ, Artifact1 as aR, SetTaskPushNotificationConfigSuccessResponse as aS, TaskPushNotificationConfig2 as aT, TaskPushNotificationConfig3 as aU, JSONRPCSuccessResponse as aV, ListTaskPushNotificationConfigParams1 as aW, MessageSendConfiguration1 as aX, MessageSendParams2 as aY, OAuthFlows1 as aZ, PartBase as a_, AgentCapabilities as aa, AgentExtension as ab, AgentCard as ac, AgentInterface as ad, AgentCapabilities1 as ae, AgentProvider as af, HTTPAuthSecurityScheme as ag, OAuth2SecurityScheme as ah, OAuthFlows as ai, AuthorizationCodeOAuthFlow as aj, ClientCredentialsOAuthFlow as ak, ImplicitOAuthFlow as al, PasswordOAuthFlow as am, OpenIdConnectSecurityScheme as an, MutualTLSSecurityScheme as ao, AgentCardSignature as ap, AgentSkill as aq, AgentProvider1 as ar, Artifact as as, AuthorizationCodeOAuthFlow1 as at, JSONRPCError as au, CancelTaskSuccessResponse as av, Task as aw, Message1 as ax, TaskStatus as ay, Message2 as az, SetTaskPushNotificationConfigResponse as b, PushNotificationAuthenticationInfo1 as b0, PushNotificationConfig2 as b1, SecuritySchemeBase as b2, TaskQueryParams1 as b3, TaskStatus2 as b4, GetTaskPushNotificationConfigResponse as c, GetAuthenticatedExtendedCardSuccessResponse as d, A2ARequest as e, SecurityScheme as f, DeleteTaskPushNotificationConfigResponse as g, GetAuthenticatedExtendedCardResponse as h, JSONRPCResponse as i, ListTaskPushNotificationConfigResponse as j, TransportProtocol as k, JSONParseError as l, MethodNotFoundError as m, InvalidParamsError as n, InternalError as o, TaskNotFoundError as p, TaskNotCancelableError as q, PushNotificationNotSupportedError as r, ContentTypeNotSupportedError as s, InvalidAgentResponseError as t, AuthenticatedExtendedCardNotConfiguredError as u, SendMessageRequest as v, MessageSendParams as w, MessageSendConfiguration as x, PushNotificationConfig as y, PushNotificationAuthenticationInfo as z };
2562
+ /**
2563
+ * A2A Protocol Extension URI.
2564
+ */
2565
+ type ExtensionURI = string;
2566
+ /**
2567
+ * A collection of {@link ExtensionURI}.
2568
+ */
2569
+ type Extensions = ExtensionURI[];
2570
+ declare const Extensions: {
2571
+ /**
2572
+ * Creates new {@link Extensions} from `current` and `additional`.
2573
+ * If `current` already contains `additional` it is returned unmodified.
2574
+ */
2575
+ createFrom: (current: Extensions | undefined, additional: ExtensionURI) => Extensions;
2576
+ /**
2577
+ * Creates {@link Extensions} from comma separated extensions identifiers as per
2578
+ * https://a2a-protocol.org/latest/specification/#326-service-parameters.
2579
+ * Parses the output of `toServiceParameter`.
2580
+ */
2581
+ parseServiceParameter: (value: string | undefined) => Extensions;
2582
+ /**
2583
+ * Converts {@link Extensions} to comma separated extensions identifiers as per
2584
+ * https://a2a-protocol.org/latest/specification/#326-service-parameters.
2585
+ */
2586
+ toServiceParameter: (value: Extensions) => string;
2587
+ };
2588
+
2589
+ export { type TaskPushNotificationConfig as $, type A2AError as A, type PushNotificationAuthenticationInfo as B, type CancelTaskResponse as C, type DeleteTaskPushNotificationConfigSuccessResponse as D, Extensions as E, type Message as F, type GetTaskResponse as G, type TextPart as H, type InvalidRequestError as I, type JSONRPCErrorResponse as J, type FilePart as K, type ListTaskPushNotificationConfigSuccessResponse as L, type MySchema as M, type FileWithBytes as N, type FileWithUri as O, type Part as P, type DataPart as Q, type SendStreamingMessageRequest as R, type SendMessageResponse as S, type TaskState as T, type UnsupportedOperationError as U, type MessageSendParams1 as V, type GetTaskRequest as W, type TaskQueryParams as X, type CancelTaskRequest as Y, type TaskIdParams as Z, type SetTaskPushNotificationConfigRequest as _, type SendStreamingMessageResponse as a, type OAuthFlows1 as a$, type PushNotificationConfig1 as a0, type GetTaskPushNotificationConfigRequest as a1, type TaskIdParams1 as a2, type GetTaskPushNotificationConfigParams as a3, type TaskResubscriptionRequest as a4, type TaskIdParams2 as a5, type ListTaskPushNotificationConfigRequest as a6, type ListTaskPushNotificationConfigParams as a7, type DeleteTaskPushNotificationConfigRequest as a8, type DeleteTaskPushNotificationConfigParams as a9, type TaskStatus as aA, type Message2 as aB, type ClientCredentialsOAuthFlow1 as aC, type DeleteTaskPushNotificationConfigParams1 as aD, type FileBase as aE, type AgentCard1 as aF, type GetTaskPushNotificationConfigSuccessResponse as aG, type TaskPushNotificationConfig1 as aH, type GetTaskSuccessResponse as aI, type Task1 as aJ, type ImplicitOAuthFlow1 as aK, type JSONRPCMessage as aL, type JSONRPCRequest as aM, type SendMessageSuccessResponse as aN, type Task2 as aO, type SendStreamingMessageSuccessResponse as aP, type TaskStatusUpdateEvent as aQ, type TaskStatus1 as aR, type TaskArtifactUpdateEvent as aS, type Artifact1 as aT, type SetTaskPushNotificationConfigSuccessResponse as aU, type TaskPushNotificationConfig2 as aV, type TaskPushNotificationConfig3 as aW, type JSONRPCSuccessResponse as aX, type ListTaskPushNotificationConfigParams1 as aY, type MessageSendConfiguration1 as aZ, type MessageSendParams2 as a_, type GetAuthenticatedExtendedCardRequest as aa, type APIKeySecurityScheme as ab, type AgentCapabilities as ac, type AgentExtension as ad, type AgentCard as ae, type AgentInterface as af, type AgentCapabilities1 as ag, type AgentProvider as ah, type HTTPAuthSecurityScheme as ai, type OAuth2SecurityScheme as aj, type OAuthFlows as ak, type AuthorizationCodeOAuthFlow as al, type ClientCredentialsOAuthFlow as am, type ImplicitOAuthFlow as an, type PasswordOAuthFlow as ao, type OpenIdConnectSecurityScheme as ap, type MutualTLSSecurityScheme as aq, type AgentCardSignature as ar, type AgentSkill as as, type AgentProvider1 as at, type Artifact as au, type AuthorizationCodeOAuthFlow1 as av, type JSONRPCError as aw, type CancelTaskSuccessResponse as ax, type Task as ay, type Message1 as az, type SetTaskPushNotificationConfigResponse as b, type PartBase as b0, type PasswordOAuthFlow1 as b1, type PushNotificationAuthenticationInfo1 as b2, type PushNotificationConfig2 as b3, type SecuritySchemeBase as b4, type TaskQueryParams1 as b5, type TaskStatus2 as b6, type GetTaskPushNotificationConfigResponse as c, type GetAuthenticatedExtendedCardSuccessResponse as d, type ExtensionURI as e, type A2ARequest as f, type SecurityScheme as g, type DeleteTaskPushNotificationConfigResponse as h, type GetAuthenticatedExtendedCardResponse as i, type JSONRPCResponse as j, type ListTaskPushNotificationConfigResponse as k, type TransportProtocol as l, type JSONParseError as m, type MethodNotFoundError as n, type InvalidParamsError as o, type InternalError as p, type TaskNotFoundError as q, type TaskNotCancelableError as r, type PushNotificationNotSupportedError as s, type ContentTypeNotSupportedError as t, type InvalidAgentResponseError as u, type AuthenticatedExtendedCardNotConfiguredError as v, type SendMessageRequest as w, type MessageSendParams as x, type MessageSendConfiguration as y, type PushNotificationConfig as z };
package/dist/index.cjs CHANGED
@@ -19,13 +19,53 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
19
19
  // src/index.ts
20
20
  var index_exports = {};
21
21
  __export(index_exports, {
22
- AGENT_CARD_PATH: () => AGENT_CARD_PATH
22
+ AGENT_CARD_PATH: () => AGENT_CARD_PATH,
23
+ Extensions: () => Extensions,
24
+ HTTP_EXTENSION_HEADER: () => HTTP_EXTENSION_HEADER
23
25
  });
24
26
  module.exports = __toCommonJS(index_exports);
25
27
 
26
28
  // src/constants.ts
27
29
  var AGENT_CARD_PATH = ".well-known/agent-card.json";
30
+ var HTTP_EXTENSION_HEADER = "X-A2A-Extensions";
31
+
32
+ // src/extensions.ts
33
+ var Extensions = {
34
+ /**
35
+ * Creates new {@link Extensions} from `current` and `additional`.
36
+ * If `current` already contains `additional` it is returned unmodified.
37
+ */
38
+ createFrom: (current, additional) => {
39
+ if (current?.includes(additional)) {
40
+ return current;
41
+ }
42
+ return [...current ?? [], additional];
43
+ },
44
+ /**
45
+ * Creates {@link Extensions} from comma separated extensions identifiers as per
46
+ * https://a2a-protocol.org/latest/specification/#326-service-parameters.
47
+ * Parses the output of `toServiceParameter`.
48
+ */
49
+ parseServiceParameter: (value) => {
50
+ if (!value) {
51
+ return [];
52
+ }
53
+ const unique = new Set(
54
+ value.split(",").map((ext) => ext.trim()).filter((ext) => ext.length > 0)
55
+ );
56
+ return Array.from(unique);
57
+ },
58
+ /**
59
+ * Converts {@link Extensions} to comma separated extensions identifiers as per
60
+ * https://a2a-protocol.org/latest/specification/#326-service-parameters.
61
+ */
62
+ toServiceParameter: (value) => {
63
+ return value.join(",");
64
+ }
65
+ };
28
66
  // Annotate the CommonJS export names for ESM import in node:
29
67
  0 && (module.exports = {
30
- AGENT_CARD_PATH
68
+ AGENT_CARD_PATH,
69
+ Extensions,
70
+ HTTP_EXTENSION_HEADER
31
71
  });
package/dist/index.d.cts CHANGED
@@ -1,5 +1,5 @@
1
- import { S as SendMessageResponse, a as SendStreamingMessageResponse, G as GetTaskResponse, C as CancelTaskResponse, b as SetTaskPushNotificationConfigResponse, c as GetTaskPushNotificationConfigResponse, L as ListTaskPushNotificationConfigSuccessResponse, D as DeleteTaskPushNotificationConfigSuccessResponse, d as GetAuthenticatedExtendedCardSuccessResponse, J as JSONRPCErrorResponse } from './types-DNKcmF0f.cjs';
2
- export { A as A2AError, e as A2ARequest, a9 as APIKeySecurityScheme, aa as AgentCapabilities, ae as AgentCapabilities1, ac as AgentCard, aD as AgentCard1, ap as AgentCardSignature, ab as AgentExtension, ad as AgentInterface, af as AgentProvider, ar as AgentProvider1, aq as AgentSkill, as as Artifact, aR as Artifact1, u as AuthenticatedExtendedCardNotConfiguredError, aj as AuthorizationCodeOAuthFlow, at as AuthorizationCodeOAuthFlow1, W as CancelTaskRequest, av as CancelTaskSuccessResponse, ak as ClientCredentialsOAuthFlow, aA as ClientCredentialsOAuthFlow1, s as ContentTypeNotSupportedError, N as DataPart, a7 as DeleteTaskPushNotificationConfigParams, aB as DeleteTaskPushNotificationConfigParams1, a6 as DeleteTaskPushNotificationConfigRequest, g as DeleteTaskPushNotificationConfigResponse, aC as FileBase, F as FilePart, H as FileWithBytes, K as FileWithUri, a8 as GetAuthenticatedExtendedCardRequest, h as GetAuthenticatedExtendedCardResponse, a1 as GetTaskPushNotificationConfigParams, $ as GetTaskPushNotificationConfigRequest, aE as GetTaskPushNotificationConfigSuccessResponse, R as GetTaskRequest, aG as GetTaskSuccessResponse, ag as HTTPAuthSecurityScheme, al as ImplicitOAuthFlow, aI as ImplicitOAuthFlow1, o as InternalError, t as InvalidAgentResponseError, n as InvalidParamsError, I as InvalidRequestError, l as JSONParseError, au as JSONRPCError, aJ as JSONRPCMessage, aK as JSONRPCRequest, i as JSONRPCResponse, aV as JSONRPCSuccessResponse, a5 as ListTaskPushNotificationConfigParams, aW as ListTaskPushNotificationConfigParams1, a4 as ListTaskPushNotificationConfigRequest, j as ListTaskPushNotificationConfigResponse, B as Message, ax as Message1, az as Message2, x as MessageSendConfiguration, aX as MessageSendConfiguration1, w as MessageSendParams, Q as MessageSendParams1, aY as MessageSendParams2, m as MethodNotFoundError, ao as MutualTLSSecurityScheme, M as MySchema, ah as OAuth2SecurityScheme, ai as OAuthFlows, aZ as OAuthFlows1, an as OpenIdConnectSecurityScheme, P as Part, a_ as PartBase, am as PasswordOAuthFlow, a$ as PasswordOAuthFlow1, z as PushNotificationAuthenticationInfo, b0 as PushNotificationAuthenticationInfo1, y as PushNotificationConfig, _ as PushNotificationConfig1, b1 as PushNotificationConfig2, r as PushNotificationNotSupportedError, f as SecurityScheme, b2 as SecuritySchemeBase, v as SendMessageRequest, aL as SendMessageSuccessResponse, O as SendStreamingMessageRequest, aN as SendStreamingMessageSuccessResponse, Y as SetTaskPushNotificationConfigRequest, aS as SetTaskPushNotificationConfigSuccessResponse, aw as Task, aH as Task1, aM as Task2, aQ as TaskArtifactUpdateEvent, X as TaskIdParams, a0 as TaskIdParams1, a3 as TaskIdParams2, q as TaskNotCancelableError, p as TaskNotFoundError, Z as TaskPushNotificationConfig, aF as TaskPushNotificationConfig1, aT as TaskPushNotificationConfig2, aU as TaskPushNotificationConfig3, V as TaskQueryParams, b3 as TaskQueryParams1, a2 as TaskResubscriptionRequest, T as TaskState, ay as TaskStatus, aP as TaskStatus1, b4 as TaskStatus2, aO as TaskStatusUpdateEvent, E as TextPart, k as TransportProtocol, U as UnsupportedOperationError } from './types-DNKcmF0f.cjs';
1
+ import { S as SendMessageResponse, a as SendStreamingMessageResponse, G as GetTaskResponse, C as CancelTaskResponse, b as SetTaskPushNotificationConfigResponse, c as GetTaskPushNotificationConfigResponse, L as ListTaskPushNotificationConfigSuccessResponse, D as DeleteTaskPushNotificationConfigSuccessResponse, d as GetAuthenticatedExtendedCardSuccessResponse, J as JSONRPCErrorResponse } from './extensions-DvruCIzw.cjs';
2
+ export { A as A2AError, f as A2ARequest, ab as APIKeySecurityScheme, ac as AgentCapabilities, ag as AgentCapabilities1, ae as AgentCard, aF as AgentCard1, ar as AgentCardSignature, ad as AgentExtension, af as AgentInterface, ah as AgentProvider, at as AgentProvider1, as as AgentSkill, au as Artifact, aT as Artifact1, v as AuthenticatedExtendedCardNotConfiguredError, al as AuthorizationCodeOAuthFlow, av as AuthorizationCodeOAuthFlow1, Y as CancelTaskRequest, ax as CancelTaskSuccessResponse, am as ClientCredentialsOAuthFlow, aC as ClientCredentialsOAuthFlow1, t as ContentTypeNotSupportedError, Q as DataPart, a9 as DeleteTaskPushNotificationConfigParams, aD as DeleteTaskPushNotificationConfigParams1, a8 as DeleteTaskPushNotificationConfigRequest, h as DeleteTaskPushNotificationConfigResponse, e as ExtensionURI, E as Extensions, aE as FileBase, K as FilePart, N as FileWithBytes, O as FileWithUri, aa as GetAuthenticatedExtendedCardRequest, i as GetAuthenticatedExtendedCardResponse, a3 as GetTaskPushNotificationConfigParams, a1 as GetTaskPushNotificationConfigRequest, aG as GetTaskPushNotificationConfigSuccessResponse, W as GetTaskRequest, aI as GetTaskSuccessResponse, ai as HTTPAuthSecurityScheme, an as ImplicitOAuthFlow, aK as ImplicitOAuthFlow1, p as InternalError, u as InvalidAgentResponseError, o as InvalidParamsError, I as InvalidRequestError, m as JSONParseError, aw as JSONRPCError, aL as JSONRPCMessage, aM as JSONRPCRequest, j as JSONRPCResponse, aX as JSONRPCSuccessResponse, a7 as ListTaskPushNotificationConfigParams, aY as ListTaskPushNotificationConfigParams1, a6 as ListTaskPushNotificationConfigRequest, k as ListTaskPushNotificationConfigResponse, F as Message, az as Message1, aB as Message2, y as MessageSendConfiguration, aZ as MessageSendConfiguration1, x as MessageSendParams, V as MessageSendParams1, a_ as MessageSendParams2, n as MethodNotFoundError, aq as MutualTLSSecurityScheme, M as MySchema, aj as OAuth2SecurityScheme, ak as OAuthFlows, a$ as OAuthFlows1, ap as OpenIdConnectSecurityScheme, P as Part, b0 as PartBase, ao as PasswordOAuthFlow, b1 as PasswordOAuthFlow1, B as PushNotificationAuthenticationInfo, b2 as PushNotificationAuthenticationInfo1, z as PushNotificationConfig, a0 as PushNotificationConfig1, b3 as PushNotificationConfig2, s as PushNotificationNotSupportedError, g as SecurityScheme, b4 as SecuritySchemeBase, w as SendMessageRequest, aN as SendMessageSuccessResponse, R as SendStreamingMessageRequest, aP as SendStreamingMessageSuccessResponse, _ as SetTaskPushNotificationConfigRequest, aU as SetTaskPushNotificationConfigSuccessResponse, ay as Task, aJ as Task1, aO as Task2, aS as TaskArtifactUpdateEvent, Z as TaskIdParams, a2 as TaskIdParams1, a5 as TaskIdParams2, r as TaskNotCancelableError, q as TaskNotFoundError, $ as TaskPushNotificationConfig, aH as TaskPushNotificationConfig1, aV as TaskPushNotificationConfig2, aW as TaskPushNotificationConfig3, X as TaskQueryParams, b5 as TaskQueryParams1, a4 as TaskResubscriptionRequest, T as TaskState, aA as TaskStatus, aR as TaskStatus1, b6 as TaskStatus2, aQ as TaskStatusUpdateEvent, H as TextPart, l as TransportProtocol, U as UnsupportedOperationError } from './extensions-DvruCIzw.cjs';
3
3
 
4
4
  /**
5
5
  * Represents any valid JSON-RPC response defined in the A2A protocol.
@@ -13,5 +13,9 @@ type A2AResponse = SendMessageResponse | SendStreamingMessageResponse | GetTaskR
13
13
  * The well-known path for the agent card
14
14
  */
15
15
  declare const AGENT_CARD_PATH = ".well-known/agent-card.json";
16
+ /**
17
+ * The name of the extension header used in http
18
+ */
19
+ declare const HTTP_EXTENSION_HEADER = "X-A2A-Extensions";
16
20
 
17
- export { type A2AResponse, AGENT_CARD_PATH, CancelTaskResponse, DeleteTaskPushNotificationConfigSuccessResponse, GetAuthenticatedExtendedCardSuccessResponse, GetTaskPushNotificationConfigResponse, GetTaskResponse, JSONRPCErrorResponse, ListTaskPushNotificationConfigSuccessResponse, SendMessageResponse, SendStreamingMessageResponse, SetTaskPushNotificationConfigResponse };
21
+ export { type A2AResponse, AGENT_CARD_PATH, CancelTaskResponse, DeleteTaskPushNotificationConfigSuccessResponse, GetAuthenticatedExtendedCardSuccessResponse, GetTaskPushNotificationConfigResponse, GetTaskResponse, HTTP_EXTENSION_HEADER, JSONRPCErrorResponse, ListTaskPushNotificationConfigSuccessResponse, SendMessageResponse, SendStreamingMessageResponse, SetTaskPushNotificationConfigResponse };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { S as SendMessageResponse, a as SendStreamingMessageResponse, G as GetTaskResponse, C as CancelTaskResponse, b as SetTaskPushNotificationConfigResponse, c as GetTaskPushNotificationConfigResponse, L as ListTaskPushNotificationConfigSuccessResponse, D as DeleteTaskPushNotificationConfigSuccessResponse, d as GetAuthenticatedExtendedCardSuccessResponse, J as JSONRPCErrorResponse } from './types-DNKcmF0f.js';
2
- export { A as A2AError, e as A2ARequest, a9 as APIKeySecurityScheme, aa as AgentCapabilities, ae as AgentCapabilities1, ac as AgentCard, aD as AgentCard1, ap as AgentCardSignature, ab as AgentExtension, ad as AgentInterface, af as AgentProvider, ar as AgentProvider1, aq as AgentSkill, as as Artifact, aR as Artifact1, u as AuthenticatedExtendedCardNotConfiguredError, aj as AuthorizationCodeOAuthFlow, at as AuthorizationCodeOAuthFlow1, W as CancelTaskRequest, av as CancelTaskSuccessResponse, ak as ClientCredentialsOAuthFlow, aA as ClientCredentialsOAuthFlow1, s as ContentTypeNotSupportedError, N as DataPart, a7 as DeleteTaskPushNotificationConfigParams, aB as DeleteTaskPushNotificationConfigParams1, a6 as DeleteTaskPushNotificationConfigRequest, g as DeleteTaskPushNotificationConfigResponse, aC as FileBase, F as FilePart, H as FileWithBytes, K as FileWithUri, a8 as GetAuthenticatedExtendedCardRequest, h as GetAuthenticatedExtendedCardResponse, a1 as GetTaskPushNotificationConfigParams, $ as GetTaskPushNotificationConfigRequest, aE as GetTaskPushNotificationConfigSuccessResponse, R as GetTaskRequest, aG as GetTaskSuccessResponse, ag as HTTPAuthSecurityScheme, al as ImplicitOAuthFlow, aI as ImplicitOAuthFlow1, o as InternalError, t as InvalidAgentResponseError, n as InvalidParamsError, I as InvalidRequestError, l as JSONParseError, au as JSONRPCError, aJ as JSONRPCMessage, aK as JSONRPCRequest, i as JSONRPCResponse, aV as JSONRPCSuccessResponse, a5 as ListTaskPushNotificationConfigParams, aW as ListTaskPushNotificationConfigParams1, a4 as ListTaskPushNotificationConfigRequest, j as ListTaskPushNotificationConfigResponse, B as Message, ax as Message1, az as Message2, x as MessageSendConfiguration, aX as MessageSendConfiguration1, w as MessageSendParams, Q as MessageSendParams1, aY as MessageSendParams2, m as MethodNotFoundError, ao as MutualTLSSecurityScheme, M as MySchema, ah as OAuth2SecurityScheme, ai as OAuthFlows, aZ as OAuthFlows1, an as OpenIdConnectSecurityScheme, P as Part, a_ as PartBase, am as PasswordOAuthFlow, a$ as PasswordOAuthFlow1, z as PushNotificationAuthenticationInfo, b0 as PushNotificationAuthenticationInfo1, y as PushNotificationConfig, _ as PushNotificationConfig1, b1 as PushNotificationConfig2, r as PushNotificationNotSupportedError, f as SecurityScheme, b2 as SecuritySchemeBase, v as SendMessageRequest, aL as SendMessageSuccessResponse, O as SendStreamingMessageRequest, aN as SendStreamingMessageSuccessResponse, Y as SetTaskPushNotificationConfigRequest, aS as SetTaskPushNotificationConfigSuccessResponse, aw as Task, aH as Task1, aM as Task2, aQ as TaskArtifactUpdateEvent, X as TaskIdParams, a0 as TaskIdParams1, a3 as TaskIdParams2, q as TaskNotCancelableError, p as TaskNotFoundError, Z as TaskPushNotificationConfig, aF as TaskPushNotificationConfig1, aT as TaskPushNotificationConfig2, aU as TaskPushNotificationConfig3, V as TaskQueryParams, b3 as TaskQueryParams1, a2 as TaskResubscriptionRequest, T as TaskState, ay as TaskStatus, aP as TaskStatus1, b4 as TaskStatus2, aO as TaskStatusUpdateEvent, E as TextPart, k as TransportProtocol, U as UnsupportedOperationError } from './types-DNKcmF0f.js';
1
+ import { S as SendMessageResponse, a as SendStreamingMessageResponse, G as GetTaskResponse, C as CancelTaskResponse, b as SetTaskPushNotificationConfigResponse, c as GetTaskPushNotificationConfigResponse, L as ListTaskPushNotificationConfigSuccessResponse, D as DeleteTaskPushNotificationConfigSuccessResponse, d as GetAuthenticatedExtendedCardSuccessResponse, J as JSONRPCErrorResponse } from './extensions-DvruCIzw.js';
2
+ export { A as A2AError, f as A2ARequest, ab as APIKeySecurityScheme, ac as AgentCapabilities, ag as AgentCapabilities1, ae as AgentCard, aF as AgentCard1, ar as AgentCardSignature, ad as AgentExtension, af as AgentInterface, ah as AgentProvider, at as AgentProvider1, as as AgentSkill, au as Artifact, aT as Artifact1, v as AuthenticatedExtendedCardNotConfiguredError, al as AuthorizationCodeOAuthFlow, av as AuthorizationCodeOAuthFlow1, Y as CancelTaskRequest, ax as CancelTaskSuccessResponse, am as ClientCredentialsOAuthFlow, aC as ClientCredentialsOAuthFlow1, t as ContentTypeNotSupportedError, Q as DataPart, a9 as DeleteTaskPushNotificationConfigParams, aD as DeleteTaskPushNotificationConfigParams1, a8 as DeleteTaskPushNotificationConfigRequest, h as DeleteTaskPushNotificationConfigResponse, e as ExtensionURI, E as Extensions, aE as FileBase, K as FilePart, N as FileWithBytes, O as FileWithUri, aa as GetAuthenticatedExtendedCardRequest, i as GetAuthenticatedExtendedCardResponse, a3 as GetTaskPushNotificationConfigParams, a1 as GetTaskPushNotificationConfigRequest, aG as GetTaskPushNotificationConfigSuccessResponse, W as GetTaskRequest, aI as GetTaskSuccessResponse, ai as HTTPAuthSecurityScheme, an as ImplicitOAuthFlow, aK as ImplicitOAuthFlow1, p as InternalError, u as InvalidAgentResponseError, o as InvalidParamsError, I as InvalidRequestError, m as JSONParseError, aw as JSONRPCError, aL as JSONRPCMessage, aM as JSONRPCRequest, j as JSONRPCResponse, aX as JSONRPCSuccessResponse, a7 as ListTaskPushNotificationConfigParams, aY as ListTaskPushNotificationConfigParams1, a6 as ListTaskPushNotificationConfigRequest, k as ListTaskPushNotificationConfigResponse, F as Message, az as Message1, aB as Message2, y as MessageSendConfiguration, aZ as MessageSendConfiguration1, x as MessageSendParams, V as MessageSendParams1, a_ as MessageSendParams2, n as MethodNotFoundError, aq as MutualTLSSecurityScheme, M as MySchema, aj as OAuth2SecurityScheme, ak as OAuthFlows, a$ as OAuthFlows1, ap as OpenIdConnectSecurityScheme, P as Part, b0 as PartBase, ao as PasswordOAuthFlow, b1 as PasswordOAuthFlow1, B as PushNotificationAuthenticationInfo, b2 as PushNotificationAuthenticationInfo1, z as PushNotificationConfig, a0 as PushNotificationConfig1, b3 as PushNotificationConfig2, s as PushNotificationNotSupportedError, g as SecurityScheme, b4 as SecuritySchemeBase, w as SendMessageRequest, aN as SendMessageSuccessResponse, R as SendStreamingMessageRequest, aP as SendStreamingMessageSuccessResponse, _ as SetTaskPushNotificationConfigRequest, aU as SetTaskPushNotificationConfigSuccessResponse, ay as Task, aJ as Task1, aO as Task2, aS as TaskArtifactUpdateEvent, Z as TaskIdParams, a2 as TaskIdParams1, a5 as TaskIdParams2, r as TaskNotCancelableError, q as TaskNotFoundError, $ as TaskPushNotificationConfig, aH as TaskPushNotificationConfig1, aV as TaskPushNotificationConfig2, aW as TaskPushNotificationConfig3, X as TaskQueryParams, b5 as TaskQueryParams1, a4 as TaskResubscriptionRequest, T as TaskState, aA as TaskStatus, aR as TaskStatus1, b6 as TaskStatus2, aQ as TaskStatusUpdateEvent, H as TextPart, l as TransportProtocol, U as UnsupportedOperationError } from './extensions-DvruCIzw.js';
3
3
 
4
4
  /**
5
5
  * Represents any valid JSON-RPC response defined in the A2A protocol.
@@ -13,5 +13,9 @@ type A2AResponse = SendMessageResponse | SendStreamingMessageResponse | GetTaskR
13
13
  * The well-known path for the agent card
14
14
  */
15
15
  declare const AGENT_CARD_PATH = ".well-known/agent-card.json";
16
+ /**
17
+ * The name of the extension header used in http
18
+ */
19
+ declare const HTTP_EXTENSION_HEADER = "X-A2A-Extensions";
16
20
 
17
- export { type A2AResponse, AGENT_CARD_PATH, CancelTaskResponse, DeleteTaskPushNotificationConfigSuccessResponse, GetAuthenticatedExtendedCardSuccessResponse, GetTaskPushNotificationConfigResponse, GetTaskResponse, JSONRPCErrorResponse, ListTaskPushNotificationConfigSuccessResponse, SendMessageResponse, SendStreamingMessageResponse, SetTaskPushNotificationConfigResponse };
21
+ export { type A2AResponse, AGENT_CARD_PATH, CancelTaskResponse, DeleteTaskPushNotificationConfigSuccessResponse, GetAuthenticatedExtendedCardSuccessResponse, GetTaskPushNotificationConfigResponse, GetTaskResponse, HTTP_EXTENSION_HEADER, JSONRPCErrorResponse, ListTaskPushNotificationConfigSuccessResponse, SendMessageResponse, SendStreamingMessageResponse, SetTaskPushNotificationConfigResponse };
package/dist/index.js CHANGED
@@ -1,6 +1,12 @@
1
1
  import {
2
- AGENT_CARD_PATH
3
- } from "./chunk-67JNQ6TZ.js";
2
+ AGENT_CARD_PATH,
3
+ HTTP_EXTENSION_HEADER
4
+ } from "./chunk-3QDLXHKS.js";
5
+ import {
6
+ Extensions
7
+ } from "./chunk-ZX6KNMCP.js";
4
8
  export {
5
- AGENT_CARD_PATH
9
+ AGENT_CARD_PATH,
10
+ Extensions,
11
+ HTTP_EXTENSION_HEADER
6
12
  };