@t2000/cli 5.24.1 → 5.24.2
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.
|
@@ -99283,7 +99283,7 @@ CRITICAL: When the user asks to use any external or paid API, names a provider (
|
|
|
99283
99283
|
The wallet can also HIRE OTHER AGENTS: the agent store (agents.t2000.ai) lists agents selling one-call services (market reads, data feeds, tools) with receipt-backed reputation. Browse with t2000_agents, buy with t2000_agent_pay (escrowed \u2014 auto-refund if delivery fails). The user's wallet can EARN too: reward tasks + a community task board live at mpp.t2000.ai/tasks (see the skill-hire prompt or the t2000-hire skill).
|
|
99284
99284
|
|
|
99285
99285
|
Spending is the user's own USDC and every t2000_pay call is bounded by maxPrice. For larger or multi-step spends, state the estimated cost first and proceed once the user is happy. Use t2000_balance to check funds. The v4 wallet is payments-only; savings / lending live on audric.ai.`;
|
|
99286
|
-
var PKG_VERSION = "5.24.
|
|
99286
|
+
var PKG_VERSION = "5.24.2";
|
|
99287
99287
|
console.log = (...args) => console.error("[log]", ...args);
|
|
99288
99288
|
console.warn = (...args) => console.error("[warn]", ...args);
|
|
99289
99289
|
async function startMcpServer(opts) {
|
|
@@ -99357,4 +99357,4 @@ mime-types/index.js:
|
|
|
99357
99357
|
@scure/bip39/index.js:
|
|
99358
99358
|
(*! scure-bip39 - MIT License (c) 2022 Patricio Palladino, Paul Miller (paulmillr.com) *)
|
|
99359
99359
|
*/
|
|
99360
|
-
//# sourceMappingURL=dist-
|
|
99360
|
+
//# sourceMappingURL=dist-ZX4DO4GG.js.map
|
package/dist/index.js
CHANGED
|
@@ -33109,7 +33109,7 @@ function registerMcpStart(parent) {
|
|
|
33109
33109
|
parent.command("start", { isDefault: true }).description("Start MCP server (stdio transport \u2014 for AI client integration)").option("--key <path>", "Custom wallet path (default ~/.t2000/wallet.key)").action(async (opts) => {
|
|
33110
33110
|
let mod3;
|
|
33111
33111
|
try {
|
|
33112
|
-
mod3 = await import("./dist-
|
|
33112
|
+
mod3 = await import("./dist-ZX4DO4GG.js");
|
|
33113
33113
|
} catch {
|
|
33114
33114
|
console.error("MCP server not installed. Run:\n npm install -g @t2000/mcp");
|
|
33115
33115
|
process.exit(1);
|
|
@@ -33949,7 +33949,8 @@ Subcommands:
|
|
|
33949
33949
|
const maxPrice = opts.maxPrice ? Number.parseFloat(opts.maxPrice) : opts.amount ? Number.parseFloat(opts.amount) : 1;
|
|
33950
33950
|
const gateway = opts.gateway ?? DEFAULT_GATEWAY;
|
|
33951
33951
|
const agent = await withAgent({ keyPath: opts.key });
|
|
33952
|
-
const
|
|
33952
|
+
const resolvedSeller = seller.startsWith("0x") ? seller : (await agent.resolveRecipient(seller)).address;
|
|
33953
|
+
const url = opts.amount ? `${gateway}/commerce/pay/${resolvedSeller}?amount=${encodeURIComponent(opts.amount)}` : `${gateway}/commerce/pay/${resolvedSeller}`;
|
|
33953
33954
|
const result = await agent.pay({
|
|
33954
33955
|
url,
|
|
33955
33956
|
method: "POST",
|
|
@@ -33963,7 +33964,7 @@ Subcommands:
|
|
|
33963
33964
|
const paidUsd = typeof chargedMicros === "number" ? chargedMicros / 1e6 : opts.amount ? Number.parseFloat(opts.amount) : result.cost ?? 0;
|
|
33964
33965
|
if (isJsonMode()) {
|
|
33965
33966
|
printJson({
|
|
33966
|
-
seller,
|
|
33967
|
+
seller: resolvedSeller,
|
|
33967
33968
|
amount: paidUsd,
|
|
33968
33969
|
paid: result.paid,
|
|
33969
33970
|
cost: result.cost,
|
|
@@ -33973,7 +33974,9 @@ Subcommands:
|
|
|
33973
33974
|
return;
|
|
33974
33975
|
}
|
|
33975
33976
|
printBlank();
|
|
33976
|
-
printSuccess(
|
|
33977
|
+
printSuccess(
|
|
33978
|
+
`Paid ${formatUsd(paidUsd)} to ${seller.startsWith("0x") ? truncateAddress(seller) : `${seller} (${truncateAddress(resolvedSeller)})`}`
|
|
33979
|
+
);
|
|
33977
33980
|
if (receipt) {
|
|
33978
33981
|
if (typeof receipt.refundMicros === "number" && receipt.refundMicros > 0 && typeof receipt.authorizedMicros === "number") {
|
|
33979
33982
|
printKeyValue(
|
|
@@ -34262,7 +34265,7 @@ function registerTask(program3) {
|
|
|
34262
34265
|
);
|
|
34263
34266
|
group.command("post").description(
|
|
34264
34267
|
"Post a community task \u2014 pays the FULL budget (reward \xD7 completions) into escrow via x402; auto-moderated at post time. SAVE the returned manageKey."
|
|
34265
|
-
).requiredOption("--title <text>", "What needs doing (8+ chars)").requiredOption("--description <text>", "Exactly what the worker must deliver + what proof (30+ chars)").requiredOption("--reward <usdc>", "Reward per approved completion ($0.01\u2013$50)").option("--completions <n>", "Max completions (default 1)", "1").option("--expiry-days <n>", "Days until unspent budget auto-refunds (default 7)", "7").option("--category <category>", "research | data | marketing | dev | creative | other", "other").option("--gateway <url>", `Gateway base URL (default ${DEFAULT_GATEWAY2})`).option("--force", "Override spending limits for this call (see `t2 limit`)").option("--key <path>", "Custom wallet path (default ~/.t2000/wallet.key)").action(
|
|
34268
|
+
).requiredOption("--title <text>", "What needs doing (8+ chars)").requiredOption("--description <text>", "Exactly what the worker must deliver + what proof (30+ chars)").requiredOption("--reward <usdc>", "Reward per approved completion ($0.01\u2013$50)").option("--completions <n>", "Max completions (default 1)", "1").option("--expiry-days <n>", "Days until unspent budget auto-refunds (default 7)", "7").option("--category <category>", "research | data | marketing | dev | creative | other", "other").option("--notify-email <email>", "Email me when submissions arrive + when the refund settles (per-task, one-click stop in every mail)").option("--gateway <url>", `Gateway base URL (default ${DEFAULT_GATEWAY2})`).option("--force", "Override spending limits for this call (see `t2 limit`)").option("--key <path>", "Custom wallet path (default ~/.t2000/wallet.key)").action(
|
|
34266
34269
|
async (opts) => {
|
|
34267
34270
|
try {
|
|
34268
34271
|
const gateway = opts.gateway ?? DEFAULT_GATEWAY2;
|
|
@@ -34282,7 +34285,8 @@ function registerTask(program3) {
|
|
|
34282
34285
|
rewardUsd: reward,
|
|
34283
34286
|
maxCompletions: completions,
|
|
34284
34287
|
expiryDays: Number.parseInt(opts.expiryDays, 10),
|
|
34285
|
-
category: opts.category
|
|
34288
|
+
category: opts.category,
|
|
34289
|
+
...opts.notifyEmail ? { notifyEmail: opts.notifyEmail } : {}
|
|
34286
34290
|
}),
|
|
34287
34291
|
maxPrice: budget,
|
|
34288
34292
|
force: opts.force
|