@jsonrecon/mcp-server 1.3.0 → 1.3.1
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.js +8 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -7,7 +7,12 @@ import { wrapAxiosWithPayment, x402Client, } from "@x402/axios";
|
|
|
7
7
|
import { ExactEvmScheme } from "@x402/evm/exact/client";
|
|
8
8
|
import { privateKeyToAccount } from "viem/accounts";
|
|
9
9
|
import { TOOLS } from "./tools.js";
|
|
10
|
-
const VERSION = "1.3.
|
|
10
|
+
const VERSION = "1.3.1";
|
|
11
|
+
const CLIENT_ID = `mcp-server/${VERSION}`;
|
|
12
|
+
const CLIENT_HEADERS = Object.freeze({
|
|
13
|
+
"User-Agent": `@jsonrecon/mcp-server/${VERSION}`,
|
|
14
|
+
"X-JSONRecon-Client": CLIENT_ID,
|
|
15
|
+
});
|
|
11
16
|
const BASE_NETWORK = "eip155:8453";
|
|
12
17
|
const BASE_USDC = "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913";
|
|
13
18
|
const DEFAULT_ENDPOINT = "https://jsonrecon.com";
|
|
@@ -76,6 +81,7 @@ const endpoint = normalizeEndpoint(process.env.JSONRECON_ENDPOINT || DEFAULT_END
|
|
|
76
81
|
const endpointOrigin = endpoint.origin;
|
|
77
82
|
const plainApi = axios.create({
|
|
78
83
|
baseURL: endpointOrigin,
|
|
84
|
+
headers: CLIENT_HEADERS,
|
|
79
85
|
maxRedirects: 0,
|
|
80
86
|
timeout: 120_000,
|
|
81
87
|
});
|
|
@@ -130,6 +136,7 @@ function createX402Api(route) {
|
|
|
130
136
|
});
|
|
131
137
|
return wrapAxiosWithPayment(axios.create({
|
|
132
138
|
baseURL: endpointOrigin,
|
|
139
|
+
headers: CLIENT_HEADERS,
|
|
133
140
|
maxRedirects: 0,
|
|
134
141
|
timeout: 120_000,
|
|
135
142
|
}), client);
|