@artinet/fleet 0.1.0-canary.7 → 0.1.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/README.md CHANGED
@@ -1,5 +1,5 @@
1
1
  <p align="center">
2
- <a href="https://artinet.io"><img src="https://img.shields.io/badge/website-artinet.io-black" alt="Website"></a>
2
+ <a href="https://artinet.io"><img src="https://img.shields.io/badge/website-artinet.io-black" alt="Website"></a>
3
3
  <a href="https://www.npmjs.com/package/@artinet/fleet"><img src="https://img.shields.io/npm/v/@artinet/fleet?color=black" alt="Downloads"></a>
4
4
  <a><img src="https://img.shields.io/badge/License-Apache_2.0-black.svg" alt="License"></a>
5
5
  <a href="https://snyk.io/test/npm/@artinet/fleet"><img src="https://snyk.io/test/npm/@artinet/fleet/badge.svg" alt="Known Vulnerabilities"></a>
@@ -33,7 +33,7 @@ npm install express
33
33
  ```typescript
34
34
  import { fleet } from "@artinet/fleet/express";
35
35
 
36
- const { app } = fleet().launch(3000);
36
+ fleet().launch(3000);
37
37
  ```
38
38
 
39
39
  **Hono**:
@@ -45,7 +45,7 @@ npm install hono
45
45
  ```typescript
46
46
  import { fleet } from "@artinet/fleet/hono";
47
47
 
48
- const { app } = fleet().launch(3000);
48
+ fleet().launch(3000);
49
49
  ```
50
50
 
51
51
  > 🚧 **More servers coming soon** — Bun adapters and edge support are on the roadmap.
@@ -76,7 +76,7 @@ const myFleet = await fleet().ship([
76
76
  myFleet.launch(3000);
77
77
  ```
78
78
 
79
- **Ship**:
79
+ **Post Launch, Ship**:
80
80
 
81
81
  ```typescript
82
82
  import { ship } from "@artinet/fleet";
@@ -110,7 +110,6 @@ curl -X POST http://localhost:3000/deploy \
110
110
  "type": "mcp",
111
111
  "uri": "everything-server-1",
112
112
  "info": {
113
- "uri": "everything-server-1",
114
113
  "implementation": {
115
114
  "version": "0.0.1",
116
115
  "name": "everything"
@@ -155,17 +154,19 @@ curl -X POST http://localhost:3000/agentId/my-agent \
155
154
  or via the [sdk](https://github.com/the-artinet-project/artinet-sdk):
156
155
 
157
156
  ```typescript
158
- import { A2AClient } from "@artinet/sdk";
157
+ import { createMessenger } from "@artinet/sdk";
159
158
 
160
- const client = new A2AClient("http://localhost:3000/agentId/my-agent");
159
+ const messenger = createMessenger({
160
+ baseUrl: "http://localhost:3000/agentId/my-agent",
161
+ });
161
162
 
162
163
  // Send a message
163
- const response = await client.sendMessage("Hello!");
164
+ const response = await messenger.sendMessage("Hello!");
164
165
 
165
166
  console.log(response);
166
167
 
167
168
  // Or stream the response
168
- for await (const update of client.sendStreamingMessage("Tell me a story")) {
169
+ for await (const update of messenger.sendMessageStream("Tell me a story")) {
169
170
  console.log(update);
170
171
  }
171
172
  ```
@@ -195,7 +196,7 @@ fleet({
195
196
 
196
197
  ### Logging
197
198
 
198
- Settup a custom logger via the [@artinet/sdk](https://www.npmjs.com/package/@artinet/sdk):
199
+ Setup a custom logger via the [@artinet/sdk](https://www.npmjs.com/package/@artinet/sdk):
199
200
 
200
201
  ```bash
201
202
  npm install @artinet/sdk pino pino-pretty
package/dist/default.d.ts CHANGED
@@ -23,13 +23,13 @@ export declare const DEFAULTS: {
23
23
  outputModes?: string[] | undefined;
24
24
  security?: Record<string, string[]>[] | undefined;
25
25
  }[];
26
+ schemaVersion: "0.1.0";
26
27
  instructions: string;
27
28
  services: ({
28
29
  url: string;
29
30
  uri: string;
30
31
  type: "a2a";
31
32
  info: {
32
- uri: string;
33
33
  protocolVersion: string;
34
34
  name: string;
35
35
  description: string;
@@ -59,6 +59,7 @@ export declare const DEFAULTS: {
59
59
  security?: Record<string, string[]>[] | undefined;
60
60
  }[];
61
61
  id?: string | undefined;
62
+ uri?: string | undefined;
62
63
  preferredTransport?: string | undefined;
63
64
  additionalInterfaces?: {
64
65
  url: string;
@@ -72,7 +73,7 @@ export declare const DEFAULTS: {
72
73
  documentationUrl?: string | undefined;
73
74
  securitySchemes?: Record<string, {
74
75
  type: "apiKey";
75
- in: "header" | "query" | "cookie";
76
+ in: "query" | "header" | "cookie";
76
77
  name: string;
77
78
  description?: string | undefined;
78
79
  } | {
@@ -131,7 +132,6 @@ export declare const DEFAULTS: {
131
132
  uri: string;
132
133
  type: "a2a";
133
134
  info: {
134
- uri: string;
135
135
  protocolVersion: string;
136
136
  name: string;
137
137
  description: string;
@@ -161,6 +161,7 @@ export declare const DEFAULTS: {
161
161
  security?: Record<string, string[]>[] | undefined;
162
162
  }[];
163
163
  id?: string | undefined;
164
+ uri?: string | undefined;
164
165
  preferredTransport?: string | undefined;
165
166
  additionalInterfaces?: {
166
167
  url: string;
@@ -174,7 +175,7 @@ export declare const DEFAULTS: {
174
175
  documentationUrl?: string | undefined;
175
176
  securitySchemes?: Record<string, {
176
177
  type: "apiKey";
177
- in: "header" | "query" | "cookie";
178
+ in: "query" | "header" | "cookie";
178
179
  name: string;
179
180
  description?: string | undefined;
180
181
  } | {
@@ -235,7 +236,6 @@ export declare const DEFAULTS: {
235
236
  uri: string;
236
237
  type: "mcp";
237
238
  info: {
238
- uri: string;
239
239
  implementation: {
240
240
  version: string;
241
241
  name: string;
@@ -351,6 +351,7 @@ export declare const DEFAULTS: {
351
351
  title?: string | undefined;
352
352
  }[];
353
353
  id?: string | undefined;
354
+ uri?: string | undefined;
354
355
  instructions?: string | undefined;
355
356
  };
356
357
  id?: string | undefined;
@@ -360,9 +361,16 @@ export declare const DEFAULTS: {
360
361
  } | {
361
362
  uri: string;
362
363
  type: "mcp";
363
- info: {
364
- uri: string;
365
- implementation: {
364
+ id?: string | undefined;
365
+ url?: string | undefined;
366
+ headers?: Record<string, string> | undefined;
367
+ authToken?: string | undefined;
368
+ parameters?: Record<string, unknown> | undefined;
369
+ arguments?: unknown;
370
+ info?: {
371
+ id?: string | undefined;
372
+ uri?: string | undefined;
373
+ implementation?: {
366
374
  version: string;
367
375
  name: string;
368
376
  websiteUrl?: string | undefined;
@@ -374,8 +382,7 @@ export declare const DEFAULTS: {
374
382
  theme?: "light" | "dark" | undefined;
375
383
  }[] | undefined;
376
384
  title?: string | undefined;
377
- };
378
- id?: string | undefined;
385
+ } | undefined;
379
386
  serverCapabilities?: {
380
387
  experimental?: Record<string, object> | undefined;
381
388
  logging?: object | undefined;
@@ -478,13 +485,7 @@ export declare const DEFAULTS: {
478
485
  title?: string | undefined;
479
486
  }[] | undefined;
480
487
  instructions?: string | undefined;
481
- };
482
- id?: string | undefined;
483
- url?: string | undefined;
484
- headers?: Record<string, string> | undefined;
485
- authToken?: string | undefined;
486
- parameters?: Record<string, unknown> | undefined;
487
- arguments?: unknown;
488
+ } | undefined;
488
489
  })[];
489
490
  protocolVersion?: string | undefined;
490
491
  url?: string | undefined;
@@ -512,7 +513,7 @@ export declare const DEFAULTS: {
512
513
  } | undefined;
513
514
  securitySchemes?: Record<string, {
514
515
  type: "apiKey";
515
- in: "header" | "query" | "cookie";
516
+ in: "query" | "header" | "cookie";
516
517
  name: string;
517
518
  description?: string | undefined;
518
519
  } | {
@@ -566,10 +567,7 @@ export declare const DEFAULTS: {
566
567
  }[] | undefined;
567
568
  id?: string | undefined;
568
569
  modelId?: string | undefined;
569
- modelUri?: string | undefined;
570
- toolIds?: string[] | undefined;
571
570
  toolUris?: string[] | undefined;
572
- agentIds?: string[] | undefined;
573
571
  agentUris?: string[] | undefined;
574
572
  groupIds?: (string | {
575
573
  id: string;
@@ -631,7 +629,7 @@ export declare const DEFAULTS: {
631
629
  documentationUrl?: string | undefined;
632
630
  securitySchemes?: Record<string, {
633
631
  type: "apiKey";
634
- in: "header" | "query" | "cookie";
632
+ in: "query" | "header" | "cookie";
635
633
  name: string;
636
634
  description?: string | undefined;
637
635
  } | {
@@ -16,13 +16,13 @@ export declare const CreateAgent: armada.Implementation<{
16
16
  outputModes?: string[] | undefined;
17
17
  security?: Record<string, string[]>[] | undefined;
18
18
  }[];
19
+ schemaVersion: "0.1.0";
19
20
  instructions: string;
20
21
  services: ({
21
22
  url: string;
22
23
  uri: string;
23
24
  type: "a2a";
24
25
  info: {
25
- uri: string;
26
26
  protocolVersion: string;
27
27
  name: string;
28
28
  description: string;
@@ -52,6 +52,7 @@ export declare const CreateAgent: armada.Implementation<{
52
52
  security?: Record<string, string[]>[] | undefined;
53
53
  }[];
54
54
  id?: string | undefined;
55
+ uri?: string | undefined;
55
56
  preferredTransport?: string | undefined;
56
57
  additionalInterfaces?: {
57
58
  url: string;
@@ -65,7 +66,7 @@ export declare const CreateAgent: armada.Implementation<{
65
66
  documentationUrl?: string | undefined;
66
67
  securitySchemes?: Record<string, {
67
68
  type: "apiKey";
68
- in: "header" | "query" | "cookie";
69
+ in: "query" | "header" | "cookie";
69
70
  name: string;
70
71
  description?: string | undefined;
71
72
  } | {
@@ -124,7 +125,6 @@ export declare const CreateAgent: armada.Implementation<{
124
125
  uri: string;
125
126
  type: "a2a";
126
127
  info: {
127
- uri: string;
128
128
  protocolVersion: string;
129
129
  name: string;
130
130
  description: string;
@@ -154,6 +154,7 @@ export declare const CreateAgent: armada.Implementation<{
154
154
  security?: Record<string, string[]>[] | undefined;
155
155
  }[];
156
156
  id?: string | undefined;
157
+ uri?: string | undefined;
157
158
  preferredTransport?: string | undefined;
158
159
  additionalInterfaces?: {
159
160
  url: string;
@@ -167,7 +168,7 @@ export declare const CreateAgent: armada.Implementation<{
167
168
  documentationUrl?: string | undefined;
168
169
  securitySchemes?: Record<string, {
169
170
  type: "apiKey";
170
- in: "header" | "query" | "cookie";
171
+ in: "query" | "header" | "cookie";
171
172
  name: string;
172
173
  description?: string | undefined;
173
174
  } | {
@@ -228,7 +229,6 @@ export declare const CreateAgent: armada.Implementation<{
228
229
  uri: string;
229
230
  type: "mcp";
230
231
  info: {
231
- uri: string;
232
232
  implementation: {
233
233
  version: string;
234
234
  name: string;
@@ -344,6 +344,7 @@ export declare const CreateAgent: armada.Implementation<{
344
344
  title?: string | undefined;
345
345
  }[];
346
346
  id?: string | undefined;
347
+ uri?: string | undefined;
347
348
  instructions?: string | undefined;
348
349
  };
349
350
  id?: string | undefined;
@@ -353,9 +354,16 @@ export declare const CreateAgent: armada.Implementation<{
353
354
  } | {
354
355
  uri: string;
355
356
  type: "mcp";
356
- info: {
357
- uri: string;
358
- implementation: {
357
+ id?: string | undefined;
358
+ url?: string | undefined;
359
+ headers?: Record<string, string> | undefined;
360
+ authToken?: string | undefined;
361
+ parameters?: Record<string, unknown> | undefined;
362
+ arguments?: unknown;
363
+ info?: {
364
+ id?: string | undefined;
365
+ uri?: string | undefined;
366
+ implementation?: {
359
367
  version: string;
360
368
  name: string;
361
369
  websiteUrl?: string | undefined;
@@ -367,8 +375,7 @@ export declare const CreateAgent: armada.Implementation<{
367
375
  theme?: "light" | "dark" | undefined;
368
376
  }[] | undefined;
369
377
  title?: string | undefined;
370
- };
371
- id?: string | undefined;
378
+ } | undefined;
372
379
  serverCapabilities?: {
373
380
  experimental?: Record<string, object> | undefined;
374
381
  logging?: object | undefined;
@@ -471,13 +478,7 @@ export declare const CreateAgent: armada.Implementation<{
471
478
  title?: string | undefined;
472
479
  }[] | undefined;
473
480
  instructions?: string | undefined;
474
- };
475
- id?: string | undefined;
476
- url?: string | undefined;
477
- headers?: Record<string, string> | undefined;
478
- authToken?: string | undefined;
479
- parameters?: Record<string, unknown> | undefined;
480
- arguments?: unknown;
481
+ } | undefined;
481
482
  })[];
482
483
  protocolVersion?: string | undefined;
483
484
  url?: string | undefined;
@@ -505,7 +506,7 @@ export declare const CreateAgent: armada.Implementation<{
505
506
  } | undefined;
506
507
  securitySchemes?: Record<string, {
507
508
  type: "apiKey";
508
- in: "header" | "query" | "cookie";
509
+ in: "query" | "header" | "cookie";
509
510
  name: string;
510
511
  description?: string | undefined;
511
512
  } | {
@@ -559,10 +560,7 @@ export declare const CreateAgent: armada.Implementation<{
559
560
  }[] | undefined;
560
561
  id?: string | undefined;
561
562
  modelId?: string | undefined;
562
- modelUri?: string | undefined;
563
- toolIds?: string[] | undefined;
564
563
  toolUris?: string[] | undefined;
565
- agentIds?: string[] | undefined;
566
564
  agentUris?: string[] | undefined;
567
565
  groupIds?: (string | {
568
566
  id: string;
@@ -624,7 +622,7 @@ export declare const CreateAgent: armada.Implementation<{
624
622
  documentationUrl?: string | undefined;
625
623
  securitySchemes?: Record<string, {
626
624
  type: "apiKey";
627
- in: "header" | "query" | "cookie";
625
+ in: "query" | "header" | "cookie";
628
626
  name: string;
629
627
  description?: string | undefined;
630
628
  } | {
@@ -687,7 +685,7 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
687
685
  timestamp: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
688
686
  agentId: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
689
687
  config: import("zod/v4").ZodObject<{
690
- uri: import("zod/v4").ZodString;
688
+ uri: import("zod/v4").ZodNonOptional<import("zod/v4").ZodOptional<import("zod/v4").ZodString>>;
691
689
  protocolVersion: import("zod/v4").ZodOptional<import("zod/v4").ZodDefault<import("zod/v4").ZodString>>;
692
690
  name: import("zod/v4").ZodString;
693
691
  description: import("zod/v4").ZodString;
@@ -727,8 +725,8 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
727
725
  description: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
728
726
  type: import("zod/v4").ZodLiteral<"apiKey">;
729
727
  in: import("zod/v4").ZodEnum<{
730
- header: "header";
731
728
  query: "query";
729
+ header: "header";
732
730
  cookie: "cookie";
733
731
  }>;
734
732
  name: import("zod/v4").ZodString;
@@ -791,12 +789,10 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
791
789
  signature: import("zod/v4").ZodString;
792
790
  header: import("zod/v4").ZodOptional<import("zod/v4").ZodRecord<import("zod/v4").ZodString, import("zod/v4").ZodUnknown>>;
793
791
  }, import("zod/v4/core").$strip>>>;
792
+ schemaVersion: import("zod/v4").ZodLiteral<"0.1.0">;
794
793
  id: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
795
794
  modelId: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
796
- modelUri: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
797
- toolIds: import("zod/v4").ZodOptional<import("zod/v4").ZodArray<import("zod/v4").ZodString>>;
798
795
  toolUris: import("zod/v4").ZodOptional<import("zod/v4").ZodArray<import("zod/v4").ZodString>>;
799
- agentIds: import("zod/v4").ZodOptional<import("zod/v4").ZodArray<import("zod/v4").ZodString>>;
800
796
  agentUris: import("zod/v4").ZodOptional<import("zod/v4").ZodArray<import("zod/v4").ZodString>>;
801
797
  groupIds: import("zod/v4").ZodOptional<import("zod/v4").ZodArray<import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodObject<{
802
798
  id: import("zod/v4").ZodString;
@@ -813,7 +809,7 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
813
809
  type: import("zod/v4").ZodDefault<import("zod/v4").ZodLiteral<"a2a">>;
814
810
  info: import("zod/v4").ZodObject<{
815
811
  id: import("zod/v4").ZodOptional<import("zod/v4").ZodOptional<import("zod/v4").ZodString>>;
816
- uri: import("zod/v4").ZodString;
812
+ uri: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
817
813
  protocolVersion: import("zod/v4").ZodDefault<import("zod/v4").ZodString>;
818
814
  name: import("zod/v4").ZodString;
819
815
  description: import("zod/v4").ZodString;
@@ -853,8 +849,8 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
853
849
  description: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
854
850
  type: import("zod/v4").ZodLiteral<"apiKey">;
855
851
  in: import("zod/v4").ZodEnum<{
856
- header: "header";
857
852
  query: "query";
853
+ header: "header";
858
854
  cookie: "cookie";
859
855
  }>;
860
856
  name: import("zod/v4").ZodString;
@@ -928,7 +924,7 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
928
924
  type: import("zod/v4").ZodDefault<import("zod/v4").ZodLiteral<"a2a">>;
929
925
  info: import("zod/v4").ZodObject<{
930
926
  id: import("zod/v4").ZodOptional<import("zod/v4").ZodOptional<import("zod/v4").ZodString>>;
931
- uri: import("zod/v4").ZodString;
927
+ uri: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
932
928
  protocolVersion: import("zod/v4").ZodDefault<import("zod/v4").ZodString>;
933
929
  name: import("zod/v4").ZodString;
934
930
  description: import("zod/v4").ZodString;
@@ -968,8 +964,8 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
968
964
  description: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
969
965
  type: import("zod/v4").ZodLiteral<"apiKey">;
970
966
  in: import("zod/v4").ZodEnum<{
971
- header: "header";
972
967
  query: "query";
968
+ header: "header";
973
969
  cookie: "cookie";
974
970
  }>;
975
971
  name: import("zod/v4").ZodString;
@@ -1043,7 +1039,7 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
1043
1039
  type: import("zod/v4").ZodDefault<import("zod/v4").ZodLiteral<"mcp">>;
1044
1040
  info: import("zod/v4").ZodObject<{
1045
1041
  id: import("zod/v4").ZodOptional<import("zod/v4").ZodOptional<import("zod/v4").ZodString>>;
1046
- uri: import("zod/v4").ZodString;
1042
+ uri: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
1047
1043
  implementation: import("zod/v4").ZodObject<{
1048
1044
  version: import("zod/v4").ZodString;
1049
1045
  websiteUrl: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
@@ -1182,10 +1178,10 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
1182
1178
  command: import("zod/v4").ZodString;
1183
1179
  args: import("zod/v4").ZodArray<import("zod/v4").ZodString>;
1184
1180
  }, import("zod/v4/core").$strip>, import("zod/v4").ZodString, import("zod/v4").ZodUnknown]>>;
1185
- info: import("zod/v4").ZodObject<{
1181
+ info: import("zod/v4").ZodOptional<import("zod/v4").ZodObject<{
1186
1182
  id: import("zod/v4").ZodOptional<import("zod/v4").ZodOptional<import("zod/v4").ZodOptional<import("zod/v4").ZodString>>>;
1187
- uri: import("zod/v4").ZodNonOptional<import("zod/v4").ZodOptional<import("zod/v4").ZodString>>;
1188
- implementation: import("zod/v4").ZodNonOptional<import("zod/v4").ZodOptional<import("zod/v4").ZodObject<{
1183
+ uri: import("zod/v4").ZodOptional<import("zod/v4").ZodOptional<import("zod/v4").ZodString>>;
1184
+ implementation: import("zod/v4").ZodOptional<import("zod/v4").ZodObject<{
1189
1185
  version: import("zod/v4").ZodString;
1190
1186
  websiteUrl: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
1191
1187
  description: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
@@ -1200,7 +1196,7 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
1200
1196
  }, import("zod/v4/core").$strip>>>;
1201
1197
  name: import("zod/v4").ZodString;
1202
1198
  title: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
1203
- }, import("zod/v4/core").$strip>>>;
1199
+ }, import("zod/v4/core").$strip>>;
1204
1200
  serverCapabilities: import("zod/v4").ZodOptional<import("zod/v4").ZodObject<{
1205
1201
  experimental: import("zod/v4").ZodOptional<import("zod/v4").ZodRecord<import("zod/v4").ZodString, import("zod/v4").ZodCustom<object, object>>>;
1206
1202
  logging: import("zod/v4").ZodOptional<import("zod/v4").ZodCustom<object, object>>;
@@ -1310,7 +1306,7 @@ export declare const CreateAgentRequestSchema: import("zod/v4").ZodObject<{
1310
1306
  title: import("zod/v4").ZodOptional<import("zod/v4").ZodString>;
1311
1307
  }, import("zod/v4/core").$strip>>>;
1312
1308
  instructions: import("zod/v4").ZodOptional<import("zod/v4").ZodOptional<import("zod/v4").ZodString>>;
1313
- }, import("zod/v4/core").$strip>;
1309
+ }, import("zod/v4/core").$strip>>;
1314
1310
  }, import("zod/v4/core").$strip>]>]>>>;
1315
1311
  metadata: import("zod/v4").ZodOptional<import("zod/v4").ZodRecord<import("zod/v4").ZodString, import("zod/v4").ZodString>>;
1316
1312
  }, import("zod/v4/core").$strip>;
@@ -4,8 +4,8 @@
4
4
  */
5
5
  import * as sdk from "@artinet/sdk";
6
6
  import { assert } from "console";
7
- function isClient(agent) {
8
- return agent instanceof sdk.A2AClient;
7
+ function isAgentMessenger(agent) {
8
+ return agent instanceof sdk.AgentMessenger;
9
9
  }
10
10
  export const invoke = async (type, request, invocable) => {
11
11
  let result = undefined;
@@ -70,7 +70,7 @@ export const callAgent = async (request, agent, params = { validation: "no param
70
70
  return await invoke("success", request, agent.cancelTask(params));
71
71
  }
72
72
  case "task/pushNotificationConfig/set": {
73
- if (!isClient(agent)) {
73
+ if (!isAgentMessenger(agent)) {
74
74
  throw sdk.PUSH_NOTIFICATION_NOT_SUPPORTED({
75
75
  data: {
76
76
  message: "Push notifications are not supported for clients",
@@ -78,10 +78,10 @@ export const callAgent = async (request, agent, params = { validation: "no param
78
78
  },
79
79
  });
80
80
  }
81
- return await invoke("success", request, agent.setTaskPushNotification(params));
81
+ return await invoke("success", request, agent.setTaskPushNotificationConfig(params));
82
82
  }
83
83
  case "task/pushNotificationConfig/get": {
84
- if (!isClient(agent)) {
84
+ if (!isAgentMessenger(agent)) {
85
85
  throw sdk.PUSH_NOTIFICATION_NOT_SUPPORTED({
86
86
  data: {
87
87
  message: "Push notifications are not supported for clients",
@@ -89,7 +89,7 @@ export const callAgent = async (request, agent, params = { validation: "no param
89
89
  },
90
90
  });
91
91
  }
92
- return await invoke("success", request, agent.getTaskPushNotification(params));
92
+ return await invoke("success", request, agent.getTaskPushNotificationConfig(params));
93
93
  }
94
94
  case "task/pushNotificationConfig/list": {
95
95
  throw sdk.PUSH_NOTIFICATION_NOT_SUPPORTED({
@@ -126,15 +126,15 @@ export const invokeAgent = async (request, _agent) => {
126
126
  const params = _params ?? { validation: "no params provided" };
127
127
  sdk.logger.debug(`invokeAgent[${request.method}]: incoming params: ${sdk.formatJson(params)}`);
128
128
  /* Support for A2AClient requests TBD */
129
- assert(!isClient(_agent), "A2AClient requests are not supported");
129
+ assert(!isAgentMessenger(_agent), "A2AClient requests are not supported");
130
130
  //TODO: This proxy pattern is temporary until we align the A2AClient with the latest protocol changes
131
131
  let agent = _agent;
132
- if (isClient(_agent)) {
132
+ if (isAgentMessenger(_agent)) {
133
133
  sdk.logger.debug(`invokeAgent[${request.method}]: creating proxy client`);
134
134
  agent = {
135
135
  ..._agent,
136
136
  streamMessage: async function* (params) {
137
- yield* _agent.sendStreamingMessage(params);
137
+ yield* _agent.sendMessageStream(params);
138
138
  },
139
139
  resubscribe: async function* (params) {
140
140
  yield* _agent.resubscribeTask(params);
@@ -9,11 +9,11 @@ import { Runtime } from "@artinet/types";
9
9
  const DEFAULT_INSTRUCTIONS = "You are a helpful assistant that can use tools and agents to fulfill requests.";
10
10
  const requiredAgentsNotLoaded = (config, context) => {
11
11
  return ((!context.agents || !context.agents.length) &&
12
- config.agentIds &&
13
- config.agentIds.length > 0);
12
+ config.agentUris &&
13
+ config.agentUris.length > 0);
14
14
  };
15
15
  const missingAgents = (config, context) => {
16
- return (config.agentIds?.filter((id) => !context.agents?.[id]).join(", ") ?? null);
16
+ return (config.agentUris?.filter((id) => !context.agents?.[id]).join(", ") ?? null);
17
17
  };
18
18
  export const loadAgent = async (config, context, provider = process.env.OPENAI_API_KEY
19
19
  ? openaiProvider({
@@ -6,22 +6,22 @@ import { AgentConfigurationSchema } from "agent-def";
6
6
  import * as armada from "@artinet/armada";
7
7
  import * as sdk from "@artinet/sdk";
8
8
  export const GetAgents = {
9
- trigger: ({ context }) => !!context.target && (context.target.agentIds?.length ?? 0) > 0,
9
+ trigger: ({ context }) => !!context.target && (context.target.agentUris?.length ?? 0) > 0,
10
10
  action: async ({ request, context, }) => {
11
- for (const agentId of context.target?.agentIds ?? []) {
11
+ for (const uri of context.target?.agentUris ?? []) {
12
12
  await armada.TryFindBase({ request, context }, {
13
- uri: agentId,
13
+ uri,
14
14
  throwNotFound: false,
15
15
  storage: context.storage,
16
16
  find: armada.FindAgent,
17
17
  });
18
- if (!context.found || !context.found.results[agentId]) {
18
+ if (!context.found || !context.found.results[uri]) {
19
19
  continue;
20
20
  }
21
21
  const agentConfig = await sdk
22
- .validateSchema(AgentConfigurationSchema, context.found.results[agentId])
22
+ .validateSchema(AgentConfigurationSchema, context.found.results[uri])
23
23
  .catch((error) => {
24
- sdk.logger.error(`Failed to validate agent configuration: ${agentId}`, error);
24
+ sdk.logger.error(`Failed to validate agent configuration: ${uri}`, error);
25
25
  return null;
26
26
  });
27
27
  if (!agentConfig) {
@@ -33,7 +33,7 @@ export const GetAgents = {
33
33
  }
34
34
  context.agents = {
35
35
  ...context.agents,
36
- [agentId]: agent,
36
+ [uri]: agent,
37
37
  };
38
38
  }
39
39
  return request;
@@ -17,7 +17,7 @@ export type AgentError = {
17
17
  data?: unknown;
18
18
  };
19
19
  export type AgentResponse = ResultOrError<sdk.A2A.ResponseResult | sdk.A2A.AgentCard, AgentError, sdk.A2A.Update>;
20
- export type Agent = sdk.Agent | sdk.A2AClient;
20
+ export type Agent = sdk.Agent | sdk.AgentMessenger;
21
21
  export type loadFunction = (config: AgentConfiguration, context?: RequestContext) => Promise<Agent | undefined>;
22
22
  export type invokeFunction = <Req extends AgentRequest = AgentRequest>(request: Req, agent: Agent, context?: RequestContext) => Promise<AgentResponse | null>;
23
23
  export interface RequestContext extends armada.StorageContext<typeof armada.StoredAgentSchema>, armada.FindContext<typeof armada.StoredAgentSchema> {
@@ -51,7 +51,7 @@ export declare const TestRequestSchema: z.ZodObject<{
51
51
  timestamp: z.ZodOptional<z.ZodString>;
52
52
  agentId: z.ZodOptional<z.ZodString>;
53
53
  config: z.ZodObject<{
54
- uri: z.ZodString;
54
+ uri: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
55
55
  protocolVersion: z.ZodOptional<z.ZodDefault<z.ZodString>>;
56
56
  name: z.ZodString;
57
57
  description: z.ZodString;
@@ -91,8 +91,8 @@ export declare const TestRequestSchema: z.ZodObject<{
91
91
  description: z.ZodOptional<z.ZodString>;
92
92
  type: z.ZodLiteral<"apiKey">;
93
93
  in: z.ZodEnum<{
94
- header: "header";
95
94
  query: "query";
95
+ header: "header";
96
96
  cookie: "cookie";
97
97
  }>;
98
98
  name: z.ZodString;
@@ -155,12 +155,10 @@ export declare const TestRequestSchema: z.ZodObject<{
155
155
  signature: z.ZodString;
156
156
  header: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
157
157
  }, z.core.$strip>>>;
158
+ schemaVersion: z.ZodLiteral<"0.1.0">;
158
159
  id: z.ZodOptional<z.ZodString>;
159
160
  modelId: z.ZodOptional<z.ZodString>;
160
- modelUri: z.ZodOptional<z.ZodString>;
161
- toolIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
162
161
  toolUris: z.ZodOptional<z.ZodArray<z.ZodString>>;
163
- agentIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
164
162
  agentUris: z.ZodOptional<z.ZodArray<z.ZodString>>;
165
163
  groupIds: z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
166
164
  id: z.ZodString;
@@ -177,7 +175,7 @@ export declare const TestRequestSchema: z.ZodObject<{
177
175
  type: z.ZodDefault<z.ZodLiteral<"a2a">>;
178
176
  info: z.ZodObject<{
179
177
  id: z.ZodOptional<z.ZodOptional<z.ZodString>>;
180
- uri: z.ZodString;
178
+ uri: z.ZodOptional<z.ZodString>;
181
179
  protocolVersion: z.ZodDefault<z.ZodString>;
182
180
  name: z.ZodString;
183
181
  description: z.ZodString;
@@ -217,8 +215,8 @@ export declare const TestRequestSchema: z.ZodObject<{
217
215
  description: z.ZodOptional<z.ZodString>;
218
216
  type: z.ZodLiteral<"apiKey">;
219
217
  in: z.ZodEnum<{
220
- header: "header";
221
218
  query: "query";
219
+ header: "header";
222
220
  cookie: "cookie";
223
221
  }>;
224
222
  name: z.ZodString;
@@ -292,7 +290,7 @@ export declare const TestRequestSchema: z.ZodObject<{
292
290
  type: z.ZodDefault<z.ZodLiteral<"a2a">>;
293
291
  info: z.ZodObject<{
294
292
  id: z.ZodOptional<z.ZodOptional<z.ZodString>>;
295
- uri: z.ZodString;
293
+ uri: z.ZodOptional<z.ZodString>;
296
294
  protocolVersion: z.ZodDefault<z.ZodString>;
297
295
  name: z.ZodString;
298
296
  description: z.ZodString;
@@ -332,8 +330,8 @@ export declare const TestRequestSchema: z.ZodObject<{
332
330
  description: z.ZodOptional<z.ZodString>;
333
331
  type: z.ZodLiteral<"apiKey">;
334
332
  in: z.ZodEnum<{
335
- header: "header";
336
333
  query: "query";
334
+ header: "header";
337
335
  cookie: "cookie";
338
336
  }>;
339
337
  name: z.ZodString;
@@ -407,7 +405,7 @@ export declare const TestRequestSchema: z.ZodObject<{
407
405
  type: z.ZodDefault<z.ZodLiteral<"mcp">>;
408
406
  info: z.ZodObject<{
409
407
  id: z.ZodOptional<z.ZodOptional<z.ZodString>>;
410
- uri: z.ZodString;
408
+ uri: z.ZodOptional<z.ZodString>;
411
409
  implementation: z.ZodObject<{
412
410
  version: z.ZodString;
413
411
  websiteUrl: z.ZodOptional<z.ZodString>;
@@ -546,10 +544,10 @@ export declare const TestRequestSchema: z.ZodObject<{
546
544
  command: z.ZodString;
547
545
  args: z.ZodArray<z.ZodString>;
548
546
  }, z.core.$strip>, z.ZodString, z.ZodUnknown]>>;
549
- info: z.ZodObject<{
547
+ info: z.ZodOptional<z.ZodObject<{
550
548
  id: z.ZodOptional<z.ZodOptional<z.ZodOptional<z.ZodString>>>;
551
- uri: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
552
- implementation: z.ZodNonOptional<z.ZodOptional<z.ZodObject<{
549
+ uri: z.ZodOptional<z.ZodOptional<z.ZodString>>;
550
+ implementation: z.ZodOptional<z.ZodObject<{
553
551
  version: z.ZodString;
554
552
  websiteUrl: z.ZodOptional<z.ZodString>;
555
553
  description: z.ZodOptional<z.ZodString>;
@@ -564,7 +562,7 @@ export declare const TestRequestSchema: z.ZodObject<{
564
562
  }, z.core.$strip>>>;
565
563
  name: z.ZodString;
566
564
  title: z.ZodOptional<z.ZodString>;
567
- }, z.core.$strip>>>;
565
+ }, z.core.$strip>>;
568
566
  serverCapabilities: z.ZodOptional<z.ZodObject<{
569
567
  experimental: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodCustom<object, object>>>;
570
568
  logging: z.ZodOptional<z.ZodCustom<object, object>>;
@@ -674,7 +672,7 @@ export declare const TestRequestSchema: z.ZodObject<{
674
672
  title: z.ZodOptional<z.ZodString>;
675
673
  }, z.core.$strip>>>;
676
674
  instructions: z.ZodOptional<z.ZodOptional<z.ZodString>>;
677
- }, z.core.$strip>;
675
+ }, z.core.$strip>>;
678
676
  }, z.core.$strip>]>]>>>;
679
677
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
680
678
  }, z.core.$strip>;
@@ -5,8 +5,8 @@
5
5
  import * as SDK from "@artinet/sdk";
6
6
  export class InMemoryStore extends SDK.Manager {
7
7
  async search(query) {
8
- return Array.from(this.data.values()).filter((value) => value.agentId.includes(query) ||
8
+ return Array.from(this.data.values()).filter((value) => value.uri.includes(query) ||
9
9
  value.name.includes(query) ||
10
- value.prompt.includes(query));
10
+ value.configuration?.instructions?.includes?.(query));
11
11
  }
12
12
  }
@@ -10,8 +10,8 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
10
10
  name: "fleet_agents";
11
11
  schema: undefined;
12
12
  columns: {
13
- agentUri: import("drizzle-orm/sqlite-core").SQLiteColumn<{
14
- name: "agentUri";
13
+ uri: import("drizzle-orm/sqlite-core").SQLiteColumn<{
14
+ name: "uri";
15
15
  tableName: "fleet_agents";
16
16
  dataType: "string";
17
17
  columnType: "SQLiteText";
@@ -29,25 +29,6 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
29
29
  }, {}, {
30
30
  length: undefined;
31
31
  }>;
32
- agentId: import("drizzle-orm/sqlite-core").SQLiteColumn<{
33
- name: "agentId";
34
- tableName: "fleet_agents";
35
- dataType: "string";
36
- columnType: "SQLiteText";
37
- data: string;
38
- driverParam: string;
39
- notNull: true;
40
- hasDefault: true;
41
- isPrimaryKey: false;
42
- isAutoincrement: false;
43
- hasRuntimeDefault: false;
44
- enumValues: [string, ...string[]];
45
- baseColumn: never;
46
- identity: undefined;
47
- generated: undefined;
48
- }, {}, {
49
- length: undefined;
50
- }>;
51
32
  name: import("drizzle-orm/sqlite-core").SQLiteColumn<{
52
33
  name: "name";
53
34
  tableName: "fleet_agents";
@@ -67,63 +48,6 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
67
48
  }, {}, {
68
49
  length: undefined;
69
50
  }>;
70
- prompt: import("drizzle-orm/sqlite-core").SQLiteColumn<{
71
- name: "prompt";
72
- tableName: "fleet_agents";
73
- dataType: "string";
74
- columnType: "SQLiteText";
75
- data: string;
76
- driverParam: string;
77
- notNull: true;
78
- hasDefault: true;
79
- isPrimaryKey: false;
80
- isAutoincrement: false;
81
- hasRuntimeDefault: false;
82
- enumValues: [string, ...string[]];
83
- baseColumn: never;
84
- identity: undefined;
85
- generated: undefined;
86
- }, {}, {
87
- length: undefined;
88
- }>;
89
- modelId: import("drizzle-orm/sqlite-core").SQLiteColumn<{
90
- name: "modelId";
91
- tableName: "fleet_agents";
92
- dataType: "string";
93
- columnType: "SQLiteText";
94
- data: string;
95
- driverParam: string;
96
- notNull: true;
97
- hasDefault: true;
98
- isPrimaryKey: false;
99
- isAutoincrement: false;
100
- hasRuntimeDefault: false;
101
- enumValues: [string, ...string[]];
102
- baseColumn: never;
103
- identity: undefined;
104
- generated: undefined;
105
- }, {}, {
106
- length: undefined;
107
- }>;
108
- agents: import("drizzle-orm/sqlite-core").SQLiteColumn<{
109
- name: "agents";
110
- tableName: "fleet_agents";
111
- dataType: "json";
112
- columnType: "SQLiteTextJson";
113
- data: string[];
114
- driverParam: string;
115
- notNull: true;
116
- hasDefault: true;
117
- isPrimaryKey: false;
118
- isAutoincrement: false;
119
- hasRuntimeDefault: false;
120
- enumValues: undefined;
121
- baseColumn: never;
122
- identity: undefined;
123
- generated: undefined;
124
- }, {}, {
125
- $type: string[];
126
- }>;
127
51
  version: import("drizzle-orm/sqlite-core").SQLiteColumn<{
128
52
  name: "version";
129
53
  tableName: "fleet_agents";
@@ -219,8 +143,8 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
219
143
  }, {}, {
220
144
  length: undefined;
221
145
  }>;
222
- metadata: import("drizzle-orm/sqlite-core").SQLiteColumn<{
223
- name: "metadata";
146
+ configuration: import("drizzle-orm/sqlite-core").SQLiteColumn<{
147
+ name: "configuration";
224
148
  tableName: "fleet_agents";
225
149
  dataType: "json";
226
150
  columnType: "SQLiteTextJson";
@@ -239,13 +163,13 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
239
163
  outputModes?: string[] | undefined;
240
164
  security?: Record<string, string[]>[] | undefined;
241
165
  }[];
166
+ schemaVersion: "0.1.0";
242
167
  instructions: string;
243
168
  services: ({
244
169
  url: string;
245
170
  uri: string;
246
171
  type: "a2a";
247
172
  info: {
248
- uri: string;
249
173
  protocolVersion: string;
250
174
  name: string;
251
175
  description: string;
@@ -275,6 +199,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
275
199
  security?: Record<string, string[]>[] | undefined;
276
200
  }[];
277
201
  id?: string | undefined;
202
+ uri?: string | undefined;
278
203
  preferredTransport?: string | undefined;
279
204
  additionalInterfaces?: {
280
205
  url: string;
@@ -288,7 +213,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
288
213
  documentationUrl?: string | undefined;
289
214
  securitySchemes?: Record<string, {
290
215
  type: "apiKey";
291
- in: "header" | "query" | "cookie";
216
+ in: "query" | "header" | "cookie";
292
217
  name: string;
293
218
  description?: string | undefined;
294
219
  } | {
@@ -347,7 +272,6 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
347
272
  uri: string;
348
273
  type: "a2a";
349
274
  info: {
350
- uri: string;
351
275
  protocolVersion: string;
352
276
  name: string;
353
277
  description: string;
@@ -377,6 +301,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
377
301
  security?: Record<string, string[]>[] | undefined;
378
302
  }[];
379
303
  id?: string | undefined;
304
+ uri?: string | undefined;
380
305
  preferredTransport?: string | undefined;
381
306
  additionalInterfaces?: {
382
307
  url: string;
@@ -390,7 +315,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
390
315
  documentationUrl?: string | undefined;
391
316
  securitySchemes?: Record<string, {
392
317
  type: "apiKey";
393
- in: "header" | "query" | "cookie";
318
+ in: "query" | "header" | "cookie";
394
319
  name: string;
395
320
  description?: string | undefined;
396
321
  } | {
@@ -451,7 +376,6 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
451
376
  uri: string;
452
377
  type: "mcp";
453
378
  info: {
454
- uri: string;
455
379
  implementation: {
456
380
  version: string;
457
381
  name: string;
@@ -567,6 +491,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
567
491
  title?: string | undefined;
568
492
  }[];
569
493
  id?: string | undefined;
494
+ uri?: string | undefined;
570
495
  instructions?: string | undefined;
571
496
  };
572
497
  id?: string | undefined;
@@ -576,9 +501,16 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
576
501
  } | {
577
502
  uri: string;
578
503
  type: "mcp";
579
- info: {
580
- uri: string;
581
- implementation: {
504
+ id?: string | undefined;
505
+ url?: string | undefined;
506
+ headers?: Record<string, string> | undefined;
507
+ authToken?: string | undefined;
508
+ parameters?: Record<string, unknown> | undefined;
509
+ arguments?: unknown;
510
+ info?: {
511
+ id?: string | undefined;
512
+ uri?: string | undefined;
513
+ implementation?: {
582
514
  version: string;
583
515
  name: string;
584
516
  websiteUrl?: string | undefined;
@@ -590,8 +522,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
590
522
  theme?: "light" | "dark" | undefined;
591
523
  }[] | undefined;
592
524
  title?: string | undefined;
593
- };
594
- id?: string | undefined;
525
+ } | undefined;
595
526
  serverCapabilities?: {
596
527
  experimental?: Record<string, object> | undefined;
597
528
  logging?: object | undefined;
@@ -694,13 +625,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
694
625
  title?: string | undefined;
695
626
  }[] | undefined;
696
627
  instructions?: string | undefined;
697
- };
698
- id?: string | undefined;
699
- url?: string | undefined;
700
- headers?: Record<string, string> | undefined;
701
- authToken?: string | undefined;
702
- parameters?: Record<string, unknown> | undefined;
703
- arguments?: unknown;
628
+ } | undefined;
704
629
  })[];
705
630
  protocolVersion?: string | undefined;
706
631
  url?: string | undefined;
@@ -728,7 +653,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
728
653
  } | undefined;
729
654
  securitySchemes?: Record<string, {
730
655
  type: "apiKey";
731
- in: "header" | "query" | "cookie";
656
+ in: "query" | "header" | "cookie";
732
657
  name: string;
733
658
  description?: string | undefined;
734
659
  } | {
@@ -782,10 +707,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
782
707
  }[] | undefined;
783
708
  id?: string | undefined;
784
709
  modelId?: string | undefined;
785
- modelUri?: string | undefined;
786
- toolIds?: string[] | undefined;
787
710
  toolUris?: string[] | undefined;
788
- agentIds?: string[] | undefined;
789
711
  agentUris?: string[] | undefined;
790
712
  groupIds?: (string | {
791
713
  id: string;
@@ -794,7 +716,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
794
716
  metadata?: Record<string, string> | undefined;
795
717
  };
796
718
  driverParam: string;
797
- notNull: true;
719
+ notNull: false;
798
720
  hasDefault: false;
799
721
  isPrimaryKey: false;
800
722
  isAutoincrement: false;
@@ -819,13 +741,13 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
819
741
  outputModes?: string[] | undefined;
820
742
  security?: Record<string, string[]>[] | undefined;
821
743
  }[];
744
+ schemaVersion: "0.1.0";
822
745
  instructions: string;
823
746
  services: ({
824
747
  url: string;
825
748
  uri: string;
826
749
  type: "a2a";
827
750
  info: {
828
- uri: string;
829
751
  protocolVersion: string;
830
752
  name: string;
831
753
  description: string;
@@ -855,6 +777,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
855
777
  security?: Record<string, string[]>[] | undefined;
856
778
  }[];
857
779
  id?: string | undefined;
780
+ uri?: string | undefined;
858
781
  preferredTransport?: string | undefined;
859
782
  additionalInterfaces?: {
860
783
  url: string;
@@ -868,7 +791,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
868
791
  documentationUrl?: string | undefined;
869
792
  securitySchemes?: Record<string, {
870
793
  type: "apiKey";
871
- in: "header" | "query" | "cookie";
794
+ in: "query" | "header" | "cookie";
872
795
  name: string;
873
796
  description?: string | undefined;
874
797
  } | {
@@ -927,7 +850,6 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
927
850
  uri: string;
928
851
  type: "a2a";
929
852
  info: {
930
- uri: string;
931
853
  protocolVersion: string;
932
854
  name: string;
933
855
  description: string;
@@ -957,6 +879,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
957
879
  security?: Record<string, string[]>[] | undefined;
958
880
  }[];
959
881
  id?: string | undefined;
882
+ uri?: string | undefined;
960
883
  preferredTransport?: string | undefined;
961
884
  additionalInterfaces?: {
962
885
  url: string;
@@ -970,7 +893,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
970
893
  documentationUrl?: string | undefined;
971
894
  securitySchemes?: Record<string, {
972
895
  type: "apiKey";
973
- in: "header" | "query" | "cookie";
896
+ in: "query" | "header" | "cookie";
974
897
  name: string;
975
898
  description?: string | undefined;
976
899
  } | {
@@ -1031,7 +954,6 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
1031
954
  uri: string;
1032
955
  type: "mcp";
1033
956
  info: {
1034
- uri: string;
1035
957
  implementation: {
1036
958
  version: string;
1037
959
  name: string;
@@ -1147,6 +1069,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
1147
1069
  title?: string | undefined;
1148
1070
  }[];
1149
1071
  id?: string | undefined;
1072
+ uri?: string | undefined;
1150
1073
  instructions?: string | undefined;
1151
1074
  };
1152
1075
  id?: string | undefined;
@@ -1156,9 +1079,16 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
1156
1079
  } | {
1157
1080
  uri: string;
1158
1081
  type: "mcp";
1159
- info: {
1160
- uri: string;
1161
- implementation: {
1082
+ id?: string | undefined;
1083
+ url?: string | undefined;
1084
+ headers?: Record<string, string> | undefined;
1085
+ authToken?: string | undefined;
1086
+ parameters?: Record<string, unknown> | undefined;
1087
+ arguments?: unknown;
1088
+ info?: {
1089
+ id?: string | undefined;
1090
+ uri?: string | undefined;
1091
+ implementation?: {
1162
1092
  version: string;
1163
1093
  name: string;
1164
1094
  websiteUrl?: string | undefined;
@@ -1170,8 +1100,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
1170
1100
  theme?: "light" | "dark" | undefined;
1171
1101
  }[] | undefined;
1172
1102
  title?: string | undefined;
1173
- };
1174
- id?: string | undefined;
1103
+ } | undefined;
1175
1104
  serverCapabilities?: {
1176
1105
  experimental?: Record<string, object> | undefined;
1177
1106
  logging?: object | undefined;
@@ -1274,13 +1203,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
1274
1203
  title?: string | undefined;
1275
1204
  }[] | undefined;
1276
1205
  instructions?: string | undefined;
1277
- };
1278
- id?: string | undefined;
1279
- url?: string | undefined;
1280
- headers?: Record<string, string> | undefined;
1281
- authToken?: string | undefined;
1282
- parameters?: Record<string, unknown> | undefined;
1283
- arguments?: unknown;
1206
+ } | undefined;
1284
1207
  })[];
1285
1208
  protocolVersion?: string | undefined;
1286
1209
  url?: string | undefined;
@@ -1308,7 +1231,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
1308
1231
  } | undefined;
1309
1232
  securitySchemes?: Record<string, {
1310
1233
  type: "apiKey";
1311
- in: "header" | "query" | "cookie";
1234
+ in: "query" | "header" | "cookie";
1312
1235
  name: string;
1313
1236
  description?: string | undefined;
1314
1237
  } | {
@@ -1362,10 +1285,7 @@ export declare const agentsTable: import("drizzle-orm/sqlite-core").SQLiteTableW
1362
1285
  }[] | undefined;
1363
1286
  id?: string | undefined;
1364
1287
  modelId?: string | undefined;
1365
- modelUri?: string | undefined;
1366
- toolIds?: string[] | undefined;
1367
1288
  toolUris?: string[] | undefined;
1368
- agentIds?: string[] | undefined;
1369
1289
  agentUris?: string[] | undefined;
1370
1290
  groupIds?: (string | {
1371
1291
  id: string;
@@ -5,32 +5,20 @@
5
5
  import { eq, like, or } from "drizzle-orm";
6
6
  import { sqliteTable, text } from "drizzle-orm/sqlite-core";
7
7
  export const TABLE_NAME = "fleet_agents";
8
- const CREATE_AGENTS_TABLE_SQL = `CREATE TABLE IF NOT EXISTS ${TABLE_NAME} (agentUri TEXT PRIMARY KEY, agentId TEXT NOT NULL, name TEXT NOT NULL, prompt TEXT NOT NULL, modelId TEXT NOT NULL, agents TEXT NOT NULL, version TEXT NOT NULL, updatedAt TEXT NOT NULL, status TEXT NOT NULL, visibility TEXT NOT NULL, owner TEXT NOT NULL, metadata TEXT NOT NULL)`;
8
+ const CREATE_AGENTS_TABLE_SQL = `CREATE TABLE IF NOT EXISTS ${TABLE_NAME} (uri TEXT PRIMARY KEY, \
9
+ name TEXT NOT NULL, \
10
+ version TEXT NOT NULL, \
11
+ updatedAt TEXT NOT NULL, \
12
+ status TEXT NOT NULL, \
13
+ visibility TEXT NOT NULL, \
14
+ owner TEXT NOT NULL, \
15
+ configuration TEXT NOT NULL)`;
9
16
  export const createAgentsTable = async (db) => {
10
17
  await db.run(CREATE_AGENTS_TABLE_SQL);
11
18
  };
12
19
  export const agentsTable = sqliteTable(TABLE_NAME, {
13
- agentUri: text().primaryKey(),
14
- /**
15
- * @deprecated Use agentUri instead
16
- */
17
- agentId: text().notNull().default(""),
20
+ uri: text().primaryKey(),
18
21
  name: text().notNull(),
19
- /**
20
- * @deprecated Use metadata instead
21
- */
22
- prompt: text().notNull().default(""),
23
- /**
24
- * @deprecated Use metadata instead
25
- */
26
- modelId: text().notNull().default(""),
27
- /**
28
- * @deprecated Use metadata instead
29
- */
30
- agents: text("agents", { mode: "json" })
31
- .$type()
32
- .notNull()
33
- .default([]),
34
22
  version: text().notNull(),
35
23
  updatedAt: text().notNull(),
36
24
  status: text("status", { mode: "json" })
@@ -40,10 +28,11 @@ export const agentsTable = sqliteTable(TABLE_NAME, {
40
28
  .$type()
41
29
  .notNull(),
42
30
  owner: text().notNull(),
43
- metadata: text("metadata", { mode: "json" })
44
- .$type()
45
- .notNull(),
31
+ configuration: text("configuration", {
32
+ mode: "json",
33
+ }).$type(),
46
34
  });
35
+ //TODO: Extend Manager for caching
47
36
  export class SQLiteStore {
48
37
  db;
49
38
  constructor(db) {
@@ -54,27 +43,27 @@ export class SQLiteStore {
54
43
  return await this.db
55
44
  .select()
56
45
  .from(agentsTable)
57
- .where(eq(agentsTable.agentUri, id))
46
+ .where(eq(agentsTable.uri, id))
58
47
  .get();
59
48
  }
60
49
  async set(id, data) {
50
+ if (id !== data.uri) {
51
+ throw new Error("URI mismatch");
52
+ }
61
53
  await this.db
62
54
  .insert(agentsTable)
63
- /**forcing this until we sync the schemas properly */
64
- .values({ ...data, agentUri: id })
55
+ .values({ ...data, uri: id })
65
56
  .execute();
66
57
  }
67
58
  async delete(id) {
68
- await this.db
69
- .delete(agentsTable)
70
- .where(eq(agentsTable.agentUri, id))
71
- .execute();
59
+ await this.db.delete(agentsTable).where(eq(agentsTable.uri, id)).execute();
72
60
  }
73
61
  async search(query) {
62
+ const trimmedQuery = query.trim();
74
63
  return await this.db
75
64
  .select()
76
65
  .from(agentsTable)
77
- .where(or(eq(agentsTable.agentUri, query), like(agentsTable.name, `%${query}%`), like(agentsTable.prompt, `%${query}%`), like(agentsTable.modelId, `%${query}%`), like(agentsTable.metadata, `%${query}%`)))
66
+ .where(or(eq(agentsTable.uri, trimmedQuery), like(agentsTable.name, `%${trimmedQuery}%`), like(agentsTable.configuration, `%${trimmedQuery}%`)))
78
67
  .execute();
79
68
  }
80
69
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@artinet/fleet",
3
- "version": "0.1.0-canary.7",
3
+ "version": "0.1.0",
4
4
  "description": "A an agentic orchestration server for on premise deployment.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -53,7 +53,7 @@
53
53
  "bugs": {
54
54
  "url": "https://github.com/the-artinet-project/artinet/issues"
55
55
  },
56
- "homepage": "https://github.com/the-artinet-project/artinet#readme",
56
+ "homepage": "https://artinet.io",
57
57
  "files": [
58
58
  "dist",
59
59
  "package.json",
@@ -62,12 +62,12 @@
62
62
  ],
63
63
  "rootDir": ".",
64
64
  "dependencies": {
65
- "@artinet/armada": "^0.1.0-alpha.1",
66
- "@artinet/sdk": "^0.6.0-preview.3",
67
- "@artinet/types": "^0.0.9-alpha.4",
65
+ "@artinet/armada": "^0.1.0",
66
+ "@artinet/sdk": "^0.6.0",
67
+ "@artinet/types": "^0.0.9",
68
68
  "@sindresorhus/slugify": "^3.0.0",
69
- "agent-def": "^0.0.2-alpha.1",
70
- "orc8": "^0.0.20-alpha.3",
69
+ "agent-def": "^0.1.0",
70
+ "orc8": "^0.1.0",
71
71
  "zod": "^3.25"
72
72
  },
73
73
  "peerDependencies": {