x402-proxy 0.8.4 → 0.8.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.
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.8.6] - 2026-03-25
|
|
11
|
+
|
|
12
|
+
### Fixed
|
|
13
|
+
- Example URLs in help output and setup wizard: `/user/` corrected to `/users/` (was returning 404)
|
|
14
|
+
|
|
15
|
+
## [0.8.5] - 2026-03-24
|
|
16
|
+
|
|
17
|
+
### Fixed
|
|
18
|
+
- OpenClaw plugin: models now appear in `openclaw models` list - replaced invalid `models` field on `registerProvider()` with a `catalog` hook returning `ProviderCatalogResult`, which is required by OpenClaw's provider discovery filter
|
|
19
|
+
|
|
10
20
|
## [0.8.4] - 2026-03-24
|
|
11
21
|
|
|
12
22
|
### Fixed
|
|
@@ -237,6 +247,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
237
247
|
- Re-exports from `@x402/fetch`, `@x402/svm`, `@x402/evm`
|
|
238
248
|
|
|
239
249
|
[Unreleased]: https://github.com/cascade-protocol/x402-proxy/compare/v0.8.4...HEAD
|
|
250
|
+
[0.8.6]: https://github.com/cascade-protocol/x402-proxy/compare/v0.8.5...v0.8.6
|
|
251
|
+
[0.8.5]: https://github.com/cascade-protocol/x402-proxy/compare/v0.8.4...v0.8.5
|
|
240
252
|
[0.8.4]: https://github.com/cascade-protocol/x402-proxy/compare/v0.8.3...v0.8.4
|
|
241
253
|
[0.8.3]: https://github.com/cascade-protocol/x402-proxy/compare/v0.8.2...v0.8.3
|
|
242
254
|
[0.8.2]: https://github.com/cascade-protocol/x402-proxy/compare/v0.8.1...v0.8.2
|
package/dist/bin/cli.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { a as getHistoryPath, c as loadConfig, i as getConfigDirShort, l as loadWalletFile, s as isConfigured, u as saveConfig } from "../derive-BR6N1ZjI.js";
|
|
3
3
|
import { _ as error, b as warn, c as resolveWallet, d as displayNetwork, f as formatAmount, g as dim, h as readHistory, l as appendHistory, m as formatUsdcValue, o as walletInfoCommand, p as formatTxLine, s as buildX402Client, u as calcSpend, v as info, y as isTTY } from "../wallet-BiX5_XFY.js";
|
|
4
|
-
import { n as setupCommand } from "../setup-
|
|
4
|
+
import { n as setupCommand } from "../setup-B1r-Opou.js";
|
|
5
5
|
import { n as statusCommand } from "../status-DvSu8reM.js";
|
|
6
6
|
import { buildApplication, buildCommand, buildRouteMap, run } from "@stricli/core";
|
|
7
7
|
import pc from "picocolors";
|
|
@@ -310,7 +310,7 @@ const fetchCommand = buildCommand({
|
|
|
310
310
|
fullDescription: `Make a paid HTTP request. Payment is automatic when the server returns 402.
|
|
311
311
|
|
|
312
312
|
Examples:
|
|
313
|
-
$ x402-proxy https://twitter.surf.cascade.fyi/
|
|
313
|
+
$ x402-proxy https://twitter.surf.cascade.fyi/users/cascade_fyi
|
|
314
314
|
$ x402-proxy -X POST -d '{"url":"https://x402.org"}' https://web.surf.cascade.fyi/v1/crawl
|
|
315
315
|
$ x402-proxy https://api.example.com/data | jq '.results'`
|
|
316
316
|
},
|
|
@@ -408,7 +408,7 @@ Examples:
|
|
|
408
408
|
console.log(` ${pc.cyan("$ npx x402-proxy wallet")} Addresses and balances`);
|
|
409
409
|
console.log(` ${pc.cyan("$ npx x402-proxy wallet history")} Full payment history`);
|
|
410
410
|
console.log();
|
|
411
|
-
console.log(pc.dim(" try: ") + pc.cyan("$ npx x402-proxy https://twitter.surf.cascade.fyi/
|
|
411
|
+
console.log(pc.dim(" try: ") + pc.cyan("$ npx x402-proxy https://twitter.surf.cascade.fyi/users/cascade_fyi"));
|
|
412
412
|
console.log();
|
|
413
413
|
console.log(pc.dim(" https://github.com/cascade-protocol/x402-proxy"));
|
|
414
414
|
console.log();
|
|
@@ -450,7 +450,7 @@ Examples:
|
|
|
450
450
|
process.exit(1);
|
|
451
451
|
}
|
|
452
452
|
dim(" No wallet found. Let's set one up first.\n");
|
|
453
|
-
const { runSetup } = await import("../setup-
|
|
453
|
+
const { runSetup } = await import("../setup-CH4woul8.js");
|
|
454
454
|
await runSetup();
|
|
455
455
|
console.log();
|
|
456
456
|
wallet = resolveWallet();
|
|
@@ -860,7 +860,7 @@ Add to your MCP client config (Claude, Cursor, etc.):
|
|
|
860
860
|
}
|
|
861
861
|
const remoteClient = new Client({
|
|
862
862
|
name: "x402-proxy",
|
|
863
|
-
version: "0.8.
|
|
863
|
+
version: "0.8.6"
|
|
864
864
|
});
|
|
865
865
|
const x402Mcp = new x402MCPClient(remoteClient, x402PaymentClient, {
|
|
866
866
|
autoPayment: true,
|
|
@@ -898,7 +898,7 @@ Add to your MCP client config (Claude, Cursor, etc.):
|
|
|
898
898
|
}
|
|
899
899
|
const localServer = new Server({
|
|
900
900
|
name: "x402-proxy",
|
|
901
|
-
version: "0.8.
|
|
901
|
+
version: "0.8.6"
|
|
902
902
|
}, { capabilities: {
|
|
903
903
|
tools: tools.length > 0 ? {} : void 0,
|
|
904
904
|
resources: remoteResources.length > 0 ? {} : void 0
|
|
@@ -993,7 +993,7 @@ Add to your MCP client config (Claude, Cursor, etc.):
|
|
|
993
993
|
}));
|
|
994
994
|
const remoteClient = new Client({
|
|
995
995
|
name: "x402-proxy",
|
|
996
|
-
version: "0.8.
|
|
996
|
+
version: "0.8.6"
|
|
997
997
|
});
|
|
998
998
|
await connectTransport(remoteClient);
|
|
999
999
|
const mppClient = McpClient.wrap(remoteClient, { methods: wrappedMethods });
|
|
@@ -1008,7 +1008,7 @@ Add to your MCP client config (Claude, Cursor, etc.):
|
|
|
1008
1008
|
}
|
|
1009
1009
|
const localServer = new Server({
|
|
1010
1010
|
name: "x402-proxy",
|
|
1011
|
-
version: "0.8.
|
|
1011
|
+
version: "0.8.6"
|
|
1012
1012
|
}, { capabilities: {
|
|
1013
1013
|
tools: tools.length > 0 ? {} : void 0,
|
|
1014
1014
|
resources: remoteResources.length > 0 ? {} : void 0
|
|
@@ -1220,7 +1220,7 @@ const routes = buildRouteMap({
|
|
|
1220
1220
|
});
|
|
1221
1221
|
const app = buildApplication(routes, {
|
|
1222
1222
|
name: "x402-proxy",
|
|
1223
|
-
versionInfo: { currentVersion: "0.8.
|
|
1223
|
+
versionInfo: { currentVersion: "0.8.6" },
|
|
1224
1224
|
scanner: { caseStyle: "allow-kebab-for-camel" }
|
|
1225
1225
|
});
|
|
1226
1226
|
|
|
@@ -17,6 +17,14 @@ type ModelEntry = {
|
|
|
17
17
|
};
|
|
18
18
|
//#endregion
|
|
19
19
|
//#region src/openclaw/plugin.d.ts
|
|
20
|
+
type ProviderCatalogResult = {
|
|
21
|
+
provider: {
|
|
22
|
+
baseUrl: string;
|
|
23
|
+
api?: string;
|
|
24
|
+
authHeader?: boolean;
|
|
25
|
+
models: Array<Omit<ModelEntry, "provider">>;
|
|
26
|
+
};
|
|
27
|
+
} | null;
|
|
20
28
|
type OpenClawPluginApi = {
|
|
21
29
|
pluginConfig?: Record<string, unknown>;
|
|
22
30
|
logger: {
|
|
@@ -27,13 +35,9 @@ type OpenClawPluginApi = {
|
|
|
27
35
|
id: string;
|
|
28
36
|
label: string;
|
|
29
37
|
auth: unknown[];
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
authHeader: boolean;
|
|
34
|
-
models: Array<Omit<ModelEntry, "provider"> & {
|
|
35
|
-
input: Array<"text" | "image">;
|
|
36
|
-
}>;
|
|
38
|
+
catalog: {
|
|
39
|
+
order?: "simple" | "profile" | "paired" | "late";
|
|
40
|
+
run: (ctx: unknown) => Promise<ProviderCatalogResult>;
|
|
37
41
|
};
|
|
38
42
|
}) => void;
|
|
39
43
|
registerTool: (tool: unknown) => void;
|
package/dist/openclaw/plugin.js
CHANGED
|
@@ -726,7 +726,7 @@ function createWalletCommand(ctx) {
|
|
|
726
726
|
try {
|
|
727
727
|
const snap = await getWalletSnapshot(ctx.rpcUrl, walletAddress, ctx.historyPath);
|
|
728
728
|
const solscanUrl = `https://solscan.io/account/${walletAddress}`;
|
|
729
|
-
const lines = [`x402-proxy v0.8.
|
|
729
|
+
const lines = [`x402-proxy v0.8.6`];
|
|
730
730
|
const defaultModel = ctx.allModels[0];
|
|
731
731
|
if (defaultModel) lines.push("", `**Model** - ${defaultModel.name} (${defaultModel.provider})`);
|
|
732
732
|
lines.push("", `**[Wallet](${solscanUrl})**`, `\`${walletAddress}\``);
|
|
@@ -1026,11 +1026,14 @@ function register(api) {
|
|
|
1026
1026
|
id: name,
|
|
1027
1027
|
label: `${name} (x402)`,
|
|
1028
1028
|
auth: [],
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1029
|
+
catalog: {
|
|
1030
|
+
order: "simple",
|
|
1031
|
+
run: async () => ({ provider: {
|
|
1032
|
+
baseUrl: prov.baseUrl,
|
|
1033
|
+
api: "openai-completions",
|
|
1034
|
+
authHeader: false,
|
|
1035
|
+
models: prov.models
|
|
1036
|
+
} })
|
|
1034
1037
|
}
|
|
1035
1038
|
});
|
|
1036
1039
|
api.logger.info(`x402-proxy: ${Object.keys(raw).join(", ")} - ${allModels.length} models, ${upstreamOrigins.length} x402 endpoints`);
|
|
@@ -104,7 +104,7 @@ async function runSetup(opts) {
|
|
|
104
104
|
prompts.log.message(` Solana (USDC): Send USDC to ${pc.cyan(sol.address)}`);
|
|
105
105
|
prompts.log.message(` Base (USDC): Send USDC to ${pc.cyan(evm.address)}`);
|
|
106
106
|
prompts.log.step("Try your first request:");
|
|
107
|
-
prompts.log.message(` ${pc.cyan("$ npx x402-proxy https://twitter.surf.cascade.fyi/
|
|
107
|
+
prompts.log.message(` ${pc.cyan("$ npx x402-proxy https://twitter.surf.cascade.fyi/users/cascade_fyi")}`);
|
|
108
108
|
prompts.outro(pc.green("Setup complete!"));
|
|
109
109
|
}
|
|
110
110
|
const setupCommand = buildCommand({
|
package/package.json
CHANGED
package/dist/setup-CJwYRd78.js
DELETED