@artinet/sdk 0.5.14 → 0.5.15
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/README.md +3 -0
- package/dist/server/express/server.d.ts +24 -24
- package/dist/services/a2a/factory/builder.d.ts +24 -24
- package/dist/services/a2a/helpers/message-builder.d.ts +1 -1
- package/dist/services/a2a/helpers/message-builder.js +4 -4
- package/dist/services/a2a/methods/get-task.d.ts +47 -47
- package/dist/services/a2a/methods/send-message.js +1 -1
- package/dist/services/a2a/methods/stream-message.js +1 -1
- package/dist/services/a2a/service.d.ts +157 -157
- package/dist/services/a2a/state/load.d.ts +1 -1
- package/dist/transport/trpc/a2a/factory/router.d.ts +1096 -1096
- package/dist/transport/trpc/a2a/routes/info.d.ts +37 -37
- package/dist/transport/trpc/a2a/routes/message/route.d.ts +227 -227
- package/dist/transport/trpc/a2a/routes/tasks/route.d.ts +260 -260
- package/dist/transport/trpc/a2a/trpc.d.ts +120 -120
- package/dist/types/interfaces/services/a2a/service.d.ts +1 -1
- package/dist/types/schemas/a2a/agent.d.ts +840 -840
- package/dist/types/schemas/a2a/agent.js +23 -2
- package/dist/types/schemas/a2a/auth.d.ts +197 -197
- package/dist/types/schemas/a2a/auth.js +19 -4
- package/dist/types/schemas/a2a/error.d.ts +24 -24
- package/dist/types/schemas/a2a/message.d.ts +4525 -4525
- package/dist/types/schemas/a2a/message.js +10 -2
- package/dist/types/schemas/a2a/notification.d.ts +403 -403
- package/dist/types/schemas/a2a/notification.js +7 -3
- package/dist/types/schemas/a2a/parameters.d.ts +264 -264
- package/dist/types/schemas/a2a/parameters.js +14 -1
- package/dist/types/schemas/a2a/protocol.d.ts +6042 -6042
- package/dist/types/schemas/a2a/rpc.d.ts +20 -20
- package/dist/types/schemas/a2a/rpc.js +5 -0
- package/dist/types/schemas/a2a/task.d.ts +2536 -2536
- package/dist/types/schemas/a2a/task.js +12 -11
- package/package.json +2 -2
|
@@ -25,6 +25,7 @@ export const SecuritySchemeBaseSchema = z
|
|
|
25
25
|
description: z
|
|
26
26
|
.string()
|
|
27
27
|
.optional()
|
|
28
|
+
.nullable()
|
|
28
29
|
.describe("Description of this security scheme."),
|
|
29
30
|
})
|
|
30
31
|
.describe("Base properties shared by all security schemes.");
|
|
@@ -73,6 +74,7 @@ export const HTTPAuthSecuritySchemeSchema = SecuritySchemeBaseSchema.extend({
|
|
|
73
74
|
bearerFormat: z
|
|
74
75
|
.string()
|
|
75
76
|
.optional()
|
|
77
|
+
.nullable()
|
|
76
78
|
.describe("A hint to the client to identify how the bearer token is formatted. Bearer tokens are usually generated by an authorization server, so this information is primarily for documentation purposes."),
|
|
77
79
|
});
|
|
78
80
|
/**
|
|
@@ -104,6 +106,7 @@ export const AuthorizationCodeOAuthFlowSchema = z
|
|
|
104
106
|
.string()
|
|
105
107
|
.url()
|
|
106
108
|
.optional()
|
|
109
|
+
.nullable()
|
|
107
110
|
.describe("The URL to be used for obtaining refresh tokens. This MUST be in the form of a URL. The OAuth2 standard requires the use of TLS."),
|
|
108
111
|
/**
|
|
109
112
|
* @required The available scopes for the OAuth2 security scheme. A map between the scope name and a short
|
|
@@ -135,6 +138,7 @@ export const ClientCredentialsOAuthFlowSchema = z
|
|
|
135
138
|
.string()
|
|
136
139
|
.url()
|
|
137
140
|
.optional()
|
|
141
|
+
.nullable()
|
|
138
142
|
.describe("The URL to be used for obtaining refresh tokens. This MUST be in the form of a URL. The OAuth2 standard requires the use of TLS."),
|
|
139
143
|
/**
|
|
140
144
|
* @required The available scopes for the OAuth2 security scheme. A map between the scope name and a short
|
|
@@ -166,6 +170,7 @@ export const ImplicitOAuthFlowSchema = z
|
|
|
166
170
|
.string()
|
|
167
171
|
.url()
|
|
168
172
|
.optional()
|
|
173
|
+
.nullable()
|
|
169
174
|
.describe("The URL to be used for obtaining refresh tokens. This MUST be in the form of a URL. The OAuth2 standard requires the use of TLS."),
|
|
170
175
|
/**
|
|
171
176
|
* @required The available scopes for the OAuth2 security scheme. A map between the scope name and a short
|
|
@@ -197,6 +202,7 @@ export const PasswordOAuthFlowSchema = z
|
|
|
197
202
|
.string()
|
|
198
203
|
.url()
|
|
199
204
|
.optional()
|
|
205
|
+
.nullable()
|
|
200
206
|
.describe("The URL to be used for obtaining refresh tokens. This MUST be in the form of a URL. The OAuth2 standard requires the use of TLS."),
|
|
201
207
|
/**
|
|
202
208
|
* @required The available scopes for the OAuth2 security scheme. A map between the scope name and a short
|
|
@@ -215,19 +221,27 @@ export const OAuthFlowsSchema = z
|
|
|
215
221
|
/**
|
|
216
222
|
* @optional Configuration for the OAuth Authorization Code flow. Previously called accessCode in OpenAPI 2.0.
|
|
217
223
|
*/
|
|
218
|
-
authorizationCode: AuthorizationCodeOAuthFlowSchema.optional()
|
|
224
|
+
authorizationCode: AuthorizationCodeOAuthFlowSchema.optional()
|
|
225
|
+
.nullable()
|
|
226
|
+
.describe("Configuration for the OAuth Authorization Code flow"),
|
|
219
227
|
/**
|
|
220
228
|
* @optional Configuration for the OAuth Client Credentials flow. Previously called application in OpenAPI 2.0
|
|
221
229
|
*/
|
|
222
|
-
clientCredentials: ClientCredentialsOAuthFlowSchema.optional()
|
|
230
|
+
clientCredentials: ClientCredentialsOAuthFlowSchema.optional()
|
|
231
|
+
.nullable()
|
|
232
|
+
.describe("Configuration for the OAuth Client Credentials flow"),
|
|
223
233
|
/**
|
|
224
234
|
* @optional Configuration for the OAuth Implicit flow
|
|
225
235
|
*/
|
|
226
|
-
implicit: ImplicitOAuthFlowSchema.optional()
|
|
236
|
+
implicit: ImplicitOAuthFlowSchema.optional()
|
|
237
|
+
.nullable()
|
|
238
|
+
.describe("Configuration for the OAuth Implicit flow"),
|
|
227
239
|
/**
|
|
228
240
|
* @optional Configuration for the OAuth Resource Owner Password flow
|
|
229
241
|
*/
|
|
230
|
-
password: PasswordOAuthFlowSchema.optional()
|
|
242
|
+
password: PasswordOAuthFlowSchema.optional()
|
|
243
|
+
.nullable()
|
|
244
|
+
.describe("Configuration for the OAuth Resource Owner Password flow"),
|
|
231
245
|
})
|
|
232
246
|
.describe("The configuration of supported OAuth Flows");
|
|
233
247
|
/**
|
|
@@ -250,6 +264,7 @@ export const OAuth2SecuritySchemeSchema = SecuritySchemeBaseSchema.extend({
|
|
|
250
264
|
.string()
|
|
251
265
|
.url()
|
|
252
266
|
.optional()
|
|
267
|
+
.nullable()
|
|
253
268
|
.describe("URL to the oauth2 authorization server metadata"),
|
|
254
269
|
}).describe("OAuth2 security scheme configuration.");
|
|
255
270
|
/**
|
|
@@ -8,7 +8,7 @@ import { z } from "zod";
|
|
|
8
8
|
*/
|
|
9
9
|
export declare const ErrorCodeParseError = -32700;
|
|
10
10
|
export declare const JSONParseErrorSchema: z.ZodObject<{
|
|
11
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
11
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
12
12
|
} & {
|
|
13
13
|
code: z.ZodLiteral<-32700>;
|
|
14
14
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -27,7 +27,7 @@ export type JSONParseError = z.infer<typeof JSONParseErrorSchema>;
|
|
|
27
27
|
*/
|
|
28
28
|
export declare const ErrorCodeInvalidRequest = -32600;
|
|
29
29
|
export declare const InvalidRequestErrorSchema: z.ZodObject<{
|
|
30
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
30
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
31
31
|
} & {
|
|
32
32
|
code: z.ZodLiteral<-32600>;
|
|
33
33
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -46,7 +46,7 @@ export type InvalidRequestError = z.infer<typeof InvalidRequestErrorSchema>;
|
|
|
46
46
|
*/
|
|
47
47
|
export declare const ErrorCodeMethodNotFound = -32601;
|
|
48
48
|
export declare const MethodNotFoundErrorSchema: z.ZodObject<{
|
|
49
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
49
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
50
50
|
} & {
|
|
51
51
|
code: z.ZodLiteral<-32601>;
|
|
52
52
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -65,7 +65,7 @@ export type MethodNotFoundError = z.infer<typeof MethodNotFoundErrorSchema>;
|
|
|
65
65
|
*/
|
|
66
66
|
export declare const ErrorCodeInvalidParams = -32602;
|
|
67
67
|
export declare const InvalidParamsErrorSchema: z.ZodObject<{
|
|
68
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
68
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
69
69
|
} & {
|
|
70
70
|
code: z.ZodLiteral<-32602>;
|
|
71
71
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -84,7 +84,7 @@ export type InvalidParamsError = z.infer<typeof InvalidParamsErrorSchema>;
|
|
|
84
84
|
*/
|
|
85
85
|
export declare const ErrorCodeInternalError = -32603;
|
|
86
86
|
export declare const InternalErrorSchema: z.ZodObject<{
|
|
87
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
87
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
88
88
|
} & {
|
|
89
89
|
code: z.ZodLiteral<-32603>;
|
|
90
90
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -103,7 +103,7 @@ export type InternalError = z.infer<typeof InternalErrorSchema>;
|
|
|
103
103
|
*/
|
|
104
104
|
export declare const ErrorCodeTaskNotFound = -32001;
|
|
105
105
|
export declare const TaskNotFoundErrorSchema: z.ZodObject<{
|
|
106
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
106
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
107
107
|
} & {
|
|
108
108
|
code: z.ZodLiteral<-32001>;
|
|
109
109
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -122,7 +122,7 @@ export type TaskNotFoundError = z.infer<typeof TaskNotFoundErrorSchema>;
|
|
|
122
122
|
*/
|
|
123
123
|
export declare const ErrorCodeTaskNotCancelable = -32002;
|
|
124
124
|
export declare const TaskNotCancelableErrorSchema: z.ZodObject<{
|
|
125
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
125
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
126
126
|
} & {
|
|
127
127
|
code: z.ZodLiteral<-32002>;
|
|
128
128
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -141,7 +141,7 @@ export type TaskNotCancelableError = z.infer<typeof TaskNotCancelableErrorSchema
|
|
|
141
141
|
*/
|
|
142
142
|
export declare const ErrorCodePushNotificationNotSupported = -32003;
|
|
143
143
|
export declare const PushNotificationNotSupportedErrorSchema: z.ZodObject<{
|
|
144
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
144
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
145
145
|
} & {
|
|
146
146
|
code: z.ZodLiteral<-32003>;
|
|
147
147
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -160,7 +160,7 @@ export type PushNotificationNotSupportedError = z.infer<typeof PushNotificationN
|
|
|
160
160
|
*/
|
|
161
161
|
export declare const ErrorCodeUnsupportedOperation = -32004;
|
|
162
162
|
export declare const UnsupportedOperationErrorSchema: z.ZodObject<{
|
|
163
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
163
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
164
164
|
} & {
|
|
165
165
|
code: z.ZodLiteral<-32004>;
|
|
166
166
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -179,7 +179,7 @@ export type UnsupportedOperationError = z.infer<typeof UnsupportedOperationError
|
|
|
179
179
|
*/
|
|
180
180
|
export declare const ErrorCodeContentTypeNotSupported = -32005;
|
|
181
181
|
export declare const ContentTypeNotSupportedErrorSchema: z.ZodObject<{
|
|
182
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
182
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
183
183
|
} & {
|
|
184
184
|
code: z.ZodLiteral<-32005>;
|
|
185
185
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -198,7 +198,7 @@ export type ContentTypeNotSupportedError = z.infer<typeof ContentTypeNotSupporte
|
|
|
198
198
|
*/
|
|
199
199
|
export declare const ErrorCodeInvalidAgentResponse = -32006;
|
|
200
200
|
export declare const InvalidAgentResponseErrorSchema: z.ZodObject<{
|
|
201
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
201
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
202
202
|
} & {
|
|
203
203
|
code: z.ZodLiteral<-32006>;
|
|
204
204
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -217,7 +217,7 @@ export type InvalidAgentResponseError = z.infer<typeof InvalidAgentResponseError
|
|
|
217
217
|
*/
|
|
218
218
|
export declare const ErrorCodeAuthenticatedExtendedCardNotConfigured = -32007;
|
|
219
219
|
export declare const AuthenticatedExtendedCardNotConfiguredErrorSchema: z.ZodObject<{
|
|
220
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
220
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
221
221
|
} & {
|
|
222
222
|
code: z.ZodLiteral<-32007>;
|
|
223
223
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -237,7 +237,7 @@ export type AuthenticatedExtendedCardNotConfiguredError = z.infer<typeof Authent
|
|
|
237
237
|
export declare const KnownErrorCodeSchema: z.ZodUnion<[z.ZodLiteral<-32700>, z.ZodLiteral<-32600>, z.ZodLiteral<-32601>, z.ZodLiteral<-32602>, z.ZodLiteral<-32603>, z.ZodLiteral<-32001>, z.ZodLiteral<-32002>, z.ZodLiteral<-32003>, z.ZodLiteral<-32004>, z.ZodLiteral<-32005>, z.ZodLiteral<-32006>, z.ZodLiteral<-32007>]>;
|
|
238
238
|
export type KnownErrorCode = z.infer<typeof KnownErrorCodeSchema>;
|
|
239
239
|
export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
240
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
240
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
241
241
|
} & {
|
|
242
242
|
code: z.ZodLiteral<-32700>;
|
|
243
243
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -250,7 +250,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
250
250
|
data?: unknown;
|
|
251
251
|
message?: string | undefined;
|
|
252
252
|
}>, z.ZodObject<{
|
|
253
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
253
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
254
254
|
} & {
|
|
255
255
|
code: z.ZodLiteral<-32600>;
|
|
256
256
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -263,7 +263,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
263
263
|
data?: unknown;
|
|
264
264
|
message?: string | undefined;
|
|
265
265
|
}>, z.ZodObject<{
|
|
266
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
266
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
267
267
|
} & {
|
|
268
268
|
code: z.ZodLiteral<-32601>;
|
|
269
269
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -276,7 +276,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
276
276
|
data?: unknown;
|
|
277
277
|
message?: string | undefined;
|
|
278
278
|
}>, z.ZodObject<{
|
|
279
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
279
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
280
280
|
} & {
|
|
281
281
|
code: z.ZodLiteral<-32602>;
|
|
282
282
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -289,7 +289,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
289
289
|
data?: unknown;
|
|
290
290
|
message?: string | undefined;
|
|
291
291
|
}>, z.ZodObject<{
|
|
292
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
292
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
293
293
|
} & {
|
|
294
294
|
code: z.ZodLiteral<-32603>;
|
|
295
295
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -302,7 +302,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
302
302
|
data?: unknown;
|
|
303
303
|
message?: string | undefined;
|
|
304
304
|
}>, z.ZodObject<{
|
|
305
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
305
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
306
306
|
} & {
|
|
307
307
|
code: z.ZodLiteral<-32001>;
|
|
308
308
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -315,7 +315,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
315
315
|
data?: unknown;
|
|
316
316
|
message?: string | undefined;
|
|
317
317
|
}>, z.ZodObject<{
|
|
318
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
318
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
319
319
|
} & {
|
|
320
320
|
code: z.ZodLiteral<-32002>;
|
|
321
321
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -328,7 +328,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
328
328
|
data?: unknown;
|
|
329
329
|
message?: string | undefined;
|
|
330
330
|
}>, z.ZodObject<{
|
|
331
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
331
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
332
332
|
} & {
|
|
333
333
|
code: z.ZodLiteral<-32003>;
|
|
334
334
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -341,7 +341,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
341
341
|
data?: unknown;
|
|
342
342
|
message?: string | undefined;
|
|
343
343
|
}>, z.ZodObject<{
|
|
344
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
344
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
345
345
|
} & {
|
|
346
346
|
code: z.ZodLiteral<-32004>;
|
|
347
347
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -354,7 +354,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
354
354
|
data?: unknown;
|
|
355
355
|
message?: string | undefined;
|
|
356
356
|
}>, z.ZodObject<{
|
|
357
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
357
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
358
358
|
} & {
|
|
359
359
|
code: z.ZodLiteral<-32005>;
|
|
360
360
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -367,7 +367,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
367
367
|
data?: unknown;
|
|
368
368
|
message?: string | undefined;
|
|
369
369
|
}>, z.ZodObject<{
|
|
370
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
370
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
371
371
|
} & {
|
|
372
372
|
code: z.ZodLiteral<-32006>;
|
|
373
373
|
message: z.ZodDefault<z.ZodString>;
|
|
@@ -380,7 +380,7 @@ export declare const A2AErrorSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
380
380
|
data?: unknown;
|
|
381
381
|
message?: string | undefined;
|
|
382
382
|
}>, z.ZodObject<{
|
|
383
|
-
data: z.ZodOptional<z.ZodUnknown
|
|
383
|
+
data: z.ZodNullable<z.ZodOptional<z.ZodUnknown>>;
|
|
384
384
|
} & {
|
|
385
385
|
code: z.ZodLiteral<-32007>;
|
|
386
386
|
message: z.ZodDefault<z.ZodString>;
|