@moltium/core 0.1.26 → 0.1.28
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/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +7 -6
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -6
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1461,7 +1461,7 @@ var A2AClient = class {
|
|
|
1461
1461
|
constructor(config) {
|
|
1462
1462
|
this.config = {
|
|
1463
1463
|
agentUrl: config.agentUrl,
|
|
1464
|
-
agentCardPath: config.agentCardPath || ".well-known/agent
|
|
1464
|
+
agentCardPath: config.agentCardPath || ".well-known/agent.json",
|
|
1465
1465
|
timeout: config.timeout || 3e4
|
|
1466
1466
|
};
|
|
1467
1467
|
const agentUrl = this.config.agentUrl;
|
|
@@ -2968,7 +2968,7 @@ var AgentCardBuilder = class {
|
|
|
2968
2968
|
name: config.name,
|
|
2969
2969
|
description: config.personality.bio || `${config.name} - An autonomous AI agent`,
|
|
2970
2970
|
protocolVersion: "0.3.0",
|
|
2971
|
-
version: "0.1.
|
|
2971
|
+
version: "0.1.28",
|
|
2972
2972
|
url: `${baseUrl}/a2a/jsonrpc`,
|
|
2973
2973
|
skills,
|
|
2974
2974
|
capabilities,
|
|
@@ -3389,7 +3389,7 @@ var A2AIntegration = class {
|
|
|
3389
3389
|
const protocol = host === "localhost" || host === "127.0.0.1" ? "http" : "https";
|
|
3390
3390
|
const baseUrl = `${protocol}://${host}:${port}`;
|
|
3391
3391
|
logger9.info("A2A endpoints available:");
|
|
3392
|
-
logger9.info(` Agent Card: ${baseUrl}/.well-known/agent
|
|
3392
|
+
logger9.info(` Agent Card: ${baseUrl}/.well-known/agent.json`);
|
|
3393
3393
|
logger9.info(` JSON-RPC: ${baseUrl}/a2a/jsonrpc`);
|
|
3394
3394
|
logger9.info(` HTTP+JSON: ${baseUrl}/a2a/rest`);
|
|
3395
3395
|
}
|
|
@@ -3407,7 +3407,7 @@ function createA2AIntegration(agent, options = {}) {
|
|
|
3407
3407
|
|
|
3408
3408
|
// src/server/app.ts
|
|
3409
3409
|
var logger10 = createLogger("Server");
|
|
3410
|
-
var AGENT_CARD_PATH = ".well-known/agent
|
|
3410
|
+
var AGENT_CARD_PATH = ".well-known/agent.json";
|
|
3411
3411
|
function createApp(agent, options = {}) {
|
|
3412
3412
|
const app = express();
|
|
3413
3413
|
app.use(express.json());
|
|
@@ -3419,7 +3419,8 @@ function createApp(agent, options = {}) {
|
|
|
3419
3419
|
const host = options.host || "0.0.0.0";
|
|
3420
3420
|
const cardHost = host === "0.0.0.0" ? "localhost" : host;
|
|
3421
3421
|
const protocol = cardHost === "localhost" || cardHost === "127.0.0.1" ? "http" : "https";
|
|
3422
|
-
const
|
|
3422
|
+
const rawBaseUrl = options.a2aConfig?.baseUrl || `${protocol}://${cardHost}:${port}`;
|
|
3423
|
+
const baseUrl = rawBaseUrl.replace("://0.0.0.0:", "://localhost:");
|
|
3423
3424
|
const a2aIntegration = createA2AIntegration(agent, {
|
|
3424
3425
|
a2aConfig: {
|
|
3425
3426
|
enabled: true,
|
|
@@ -3450,7 +3451,7 @@ async function startServer(agent, options = {}) {
|
|
|
3450
3451
|
const protocol = logHost === "localhost" || logHost === "127.0.0.1" ? "http" : "https";
|
|
3451
3452
|
const baseUrl = `${protocol}://${logHost}:${port}`;
|
|
3452
3453
|
logger10.info("A2A Protocol Endpoints:");
|
|
3453
|
-
logger10.info(` Agent Card: ${baseUrl}/.well-known/agent
|
|
3454
|
+
logger10.info(` Agent Card: ${baseUrl}/.well-known/agent.json`);
|
|
3454
3455
|
logger10.info(` JSON-RPC: ${baseUrl}/a2a/jsonrpc`);
|
|
3455
3456
|
logger10.info(` HTTP+JSON: ${baseUrl}/a2a/rest`);
|
|
3456
3457
|
}
|