@totalreclaw/mcp-server 3.3.0-rc.4 → 3.4.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 +4 -7
- package/SKILL.md +6 -7
- package/dist/claims-helper.d.ts +1 -1
- package/dist/claims-helper.d.ts.map +1 -1
- package/dist/claims-helper.js +31 -31
- package/dist/claims-helper.js.map +1 -1
- package/dist/cli/setup.js +5 -5
- package/dist/cli/setup.js.map +1 -1
- package/dist/consolidation.d.ts +3 -5
- package/dist/consolidation.d.ts.map +1 -1
- package/dist/consolidation.js +47 -122
- package/dist/consolidation.js.map +1 -1
- package/dist/contradiction-sync.d.ts +2 -2
- package/dist/contradiction-sync.d.ts.map +1 -1
- package/dist/contradiction-sync.js +12 -12
- package/dist/contradiction-sync.js.map +1 -1
- package/dist/dispatch.d.ts +95 -0
- package/dist/dispatch.d.ts.map +1 -0
- package/dist/dispatch.js +191 -0
- package/dist/dispatch.js.map +1 -0
- package/dist/extraction/extractor.d.ts +1 -0
- package/dist/extraction/extractor.d.ts.map +1 -1
- package/dist/extraction/extractor.js +15 -15
- package/dist/extraction/extractor.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +207 -732
- package/dist/index.js.map +1 -1
- package/dist/prompts.d.ts +3 -4
- package/dist/prompts.d.ts.map +1 -1
- package/dist/prompts.js +5 -11
- package/dist/prompts.js.map +1 -1
- package/dist/server-setup.d.ts +35 -0
- package/dist/server-setup.d.ts.map +1 -0
- package/dist/server-setup.js +102 -0
- package/dist/server-setup.js.map +1 -0
- package/dist/subgraph/chain-config.d.ts +45 -0
- package/dist/subgraph/chain-config.d.ts.map +1 -0
- package/dist/subgraph/chain-config.js +66 -0
- package/dist/subgraph/chain-config.js.map +1 -0
- package/dist/subgraph/search.js +13 -13
- package/dist/subgraph/search.js.map +1 -1
- package/dist/subgraph/store.d.ts.map +1 -1
- package/dist/subgraph/store.js +4 -1
- package/dist/subgraph/store.js.map +1 -1
- package/dist/tools/account.d.ts +5 -2
- package/dist/tools/account.d.ts.map +1 -1
- package/dist/tools/account.js +11 -4
- package/dist/tools/account.js.map +1 -1
- package/dist/tools/consolidate.d.ts +2 -2
- package/dist/tools/consolidate.d.ts.map +1 -1
- package/dist/tools/consolidate.js +2 -1
- package/dist/tools/consolidate.js.map +1 -1
- package/dist/tools/debrief.d.ts +2 -2
- package/dist/tools/debrief.d.ts.map +1 -1
- package/dist/tools/debrief.js +2 -1
- package/dist/tools/debrief.js.map +1 -1
- package/dist/tools/export.d.ts +2 -2
- package/dist/tools/export.d.ts.map +1 -1
- package/dist/tools/export.js +2 -1
- package/dist/tools/export.js.map +1 -1
- package/dist/tools/forget.d.ts +8 -2
- package/dist/tools/forget.d.ts.map +1 -1
- package/dist/tools/forget.js +14 -7
- package/dist/tools/forget.js.map +1 -1
- package/dist/tools/helpers.d.ts +40 -0
- package/dist/tools/helpers.d.ts.map +1 -0
- package/dist/tools/helpers.js +64 -0
- package/dist/tools/helpers.js.map +1 -0
- package/dist/tools/import-batch.d.ts +2 -1
- package/dist/tools/import-batch.d.ts.map +1 -1
- package/dist/tools/import-batch.js +1 -1
- package/dist/tools/import-batch.js.map +1 -1
- package/dist/tools/import-from.d.ts +2 -2
- package/dist/tools/import-from.d.ts.map +1 -1
- package/dist/tools/import-from.js +2 -1
- package/dist/tools/import-from.js.map +1 -1
- package/dist/tools/import.d.ts +2 -2
- package/dist/tools/import.d.ts.map +1 -1
- package/dist/tools/import.js +4 -3
- package/dist/tools/import.js.map +1 -1
- package/dist/tools/index.d.ts +2 -2
- package/dist/tools/index.d.ts.map +1 -1
- package/dist/tools/index.js +7 -9
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/pair.d.ts +2 -1
- package/dist/tools/pair.d.ts.map +1 -1
- package/dist/tools/pair.js +4 -4
- package/dist/tools/pair.js.map +1 -1
- package/dist/tools/pin.d.ts +10 -7
- package/dist/tools/pin.d.ts.map +1 -1
- package/dist/tools/pin.js +43 -49
- package/dist/tools/pin.js.map +1 -1
- package/dist/tools/recall.d.ts +2 -2
- package/dist/tools/recall.d.ts.map +1 -1
- package/dist/tools/recall.js +22 -47
- package/dist/tools/recall.js.map +1 -1
- package/dist/tools/remember.d.ts +2 -2
- package/dist/tools/remember.d.ts.map +1 -1
- package/dist/tools/remember.js +30 -48
- package/dist/tools/remember.js.map +1 -1
- package/dist/tools/retype.d.ts +6 -1
- package/dist/tools/retype.d.ts.map +1 -1
- package/dist/tools/retype.js +37 -33
- package/dist/tools/retype.js.map +1 -1
- package/dist/tools/set-scope.d.ts +6 -1
- package/dist/tools/set-scope.d.ts.map +1 -1
- package/dist/tools/set-scope.js +14 -10
- package/dist/tools/set-scope.js.map +1 -1
- package/dist/tools/status.d.ts +2 -1
- package/dist/tools/status.d.ts.map +1 -1
- package/dist/tools/status.js +24 -15
- package/dist/tools/status.js.map +1 -1
- package/dist/tools/support.d.ts +5 -3
- package/dist/tools/support.d.ts.map +1 -1
- package/dist/tools/support.js +9 -8
- package/dist/tools/support.js.map +1 -1
- package/dist/tools/types.d.ts +38 -0
- package/dist/tools/types.d.ts.map +1 -0
- package/dist/tools/types.js +17 -0
- package/dist/tools/types.js.map +1 -0
- package/dist/tools/upgrade.d.ts +2 -1
- package/dist/tools/upgrade.d.ts.map +1 -1
- package/dist/tools/upgrade.js +6 -4
- package/dist/tools/upgrade.js.map +1 -1
- package/package.json +2 -3
- package/dist/subgraph/index.d.ts +0 -7
- package/dist/subgraph/index.d.ts.map +0 -1
- package/dist/subgraph/index.js +0 -23
- package/dist/subgraph/index.js.map +0 -1
- package/dist/tools/migrate.d.ts +0 -88
- package/dist/tools/migrate.d.ts.map +0 -1
- package/dist/tools/migrate.js +0 -273
- package/dist/tools/migrate.js.map +0 -1
package/dist/tools/status.js
CHANGED
|
@@ -42,7 +42,9 @@ function getLastBillingResponse() {
|
|
|
42
42
|
*
|
|
43
43
|
* Fetches billing status from the relay server and formats it for the LLM.
|
|
44
44
|
*/
|
|
45
|
-
async function handleStatus(
|
|
45
|
+
async function handleStatus(ctx, args) {
|
|
46
|
+
const serverUrl = ctx.serverUrl ?? '';
|
|
47
|
+
const authKey = ctx.authKeyHex ?? '';
|
|
46
48
|
const input = args;
|
|
47
49
|
const walletAddress = input?.wallet_address;
|
|
48
50
|
if (!walletAddress || typeof walletAddress !== 'string') {
|
|
@@ -82,16 +84,21 @@ async function handleStatus(serverUrl, authKey, args) {
|
|
|
82
84
|
}],
|
|
83
85
|
};
|
|
84
86
|
}
|
|
85
|
-
const
|
|
87
|
+
const billingJson = (await response.json());
|
|
86
88
|
// Cache the raw response for candidate pool sizing
|
|
87
|
-
lastBillingResponse =
|
|
89
|
+
lastBillingResponse = billingJson;
|
|
88
90
|
// Format nicely for the LLM to present
|
|
89
|
-
const tierLabel =
|
|
90
|
-
const usage = `${
|
|
91
|
-
const remaining =
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
91
|
+
const tierLabel = billingJson.tier === 'pro' ? 'Pro' : 'Free';
|
|
92
|
+
const usage = `${billingJson.free_writes_used}/${billingJson.free_writes_limit}`;
|
|
93
|
+
const remaining = billingJson.free_writes_limit - billingJson.free_writes_used;
|
|
94
|
+
// Both tiers have a MONTHLY quota cap (Free 250, Pro 1500). The counter
|
|
95
|
+
// resets on the 1st of each calendar month. Surface this so the agent
|
|
96
|
+
// doesn't have to guess between "monthly" vs "lifetime" when answering
|
|
97
|
+
// user questions about their cap.
|
|
98
|
+
const quotaPeriod = 'monthly';
|
|
99
|
+
const expiresLabel = billingJson.expires_at
|
|
100
|
+
? `Subscription renews: ${new Date(billingJson.expires_at).toLocaleDateString()}`
|
|
101
|
+
: 'No subscription expiry';
|
|
95
102
|
// 3.3.1 (internal#130) — echo the SA / scope address back to the
|
|
96
103
|
// agent so the user can see it pre-write. The MCP tool already takes
|
|
97
104
|
// wallet_address as a required input (the SA is derived deterministically
|
|
@@ -101,19 +108,21 @@ async function handleStatus(serverUrl, authKey, args) {
|
|
|
101
108
|
const formatted = [
|
|
102
109
|
`Tier: ${tierLabel}`,
|
|
103
110
|
`Smart Account: ${walletAddress}`,
|
|
104
|
-
`
|
|
105
|
-
`Remaining: ${remaining}`,
|
|
111
|
+
`Memories used this month: ${usage}`,
|
|
112
|
+
`Remaining this month: ${remaining}`,
|
|
113
|
+
`Quota resets: 1st of each month`,
|
|
106
114
|
expiresLabel,
|
|
107
115
|
].join('\n');
|
|
108
116
|
return {
|
|
109
117
|
content: [{
|
|
110
118
|
type: 'text',
|
|
111
119
|
text: JSON.stringify({
|
|
112
|
-
tier:
|
|
113
|
-
free_writes_used:
|
|
114
|
-
free_writes_limit:
|
|
120
|
+
tier: billingJson.tier,
|
|
121
|
+
free_writes_used: billingJson.free_writes_used,
|
|
122
|
+
free_writes_limit: billingJson.free_writes_limit,
|
|
115
123
|
remaining_writes: remaining,
|
|
116
|
-
|
|
124
|
+
quota_period: quotaPeriod,
|
|
125
|
+
expires_at: billingJson.expires_at,
|
|
117
126
|
scope_address: walletAddress,
|
|
118
127
|
formatted,
|
|
119
128
|
}),
|
package/dist/tools/status.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"status.js","sourceRoot":"","sources":["../../src/tools/status.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;
|
|
1
|
+
{"version":3,"file":"status.js","sourceRoot":"","sources":["../../src/tools/status.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAgDH,wDAEC;AAOD,oCA4GC;AAlKD,8CAAwD;AACxD,kDAA8C;AAC9C,oDAAgD;AAEnC,QAAA,oBAAoB,GAAG;IAClC,IAAI,EAAE,oBAAoB;IAC1B,WAAW,EAAE,oCAAuB;IACpC,WAAW,EAAE;QACX,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,cAAc,EAAE;gBACd,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,sDAAsD;aACpE;SACF;QACD,QAAQ,EAAE,CAAC,gBAAgB,CAAC;KAC7B;IAC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,GAAG;YAChB,SAAS,SAAS,EAAE;YACpB,kBAAkB,aAAa,EAAE;YACjC,6BAA6B,KAAK,EAAE;YACpC,yBAAyB,SAAS,EAAE;YACpC,iCAAiC;YACjC,YAAY;SACb,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAEb,OAAO;YACL,OAAO,EAAE,CAAC;oBACR,IAAI,EAAE,MAAM;oBACZ,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC;wBACnB,IAAI,EAAE,WAAW,CAAC,IAAI;wBACtB,gBAAgB,EAAE,WAAW,CAAC,gBAAgB;wBAC9C,iBAAiB,EAAE,WAAW,CAAC,iBAAiB;wBAChD,gBAAgB,EAAE,SAAS;wBAC3B,YAAY,EAAE,WAAW;wBACzB,UAAU,EAAE,WAAW,CAAC,UAAU;wBAClC,aAAa,EAAE,aAAa;wBAC5B,SAAS;qBACV,CAAC;iBACH,CAAC;SACH,CAAC;IACJ,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,OAAO,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,CAAC;QACzE,OAAO;YACL,OAAO,EAAE,CAAC;oBACR,IAAI,EAAE,MAAM;oBACZ,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC;wBACnB,KAAK,EAAE,mCAAmC,OAAO,EAAE;qBACpD,CAAC;iBACH,CAAC;SACH,CAAC;IACJ,CAAC;AACH,CAAC"}
|
package/dist/tools/support.d.ts
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
* Returns static support information and common troubleshooting steps.
|
|
5
5
|
* No server calls needed -- works in all modes including unconfigured.
|
|
6
6
|
*/
|
|
7
|
+
import type { ToolContext } from './types.js';
|
|
7
8
|
export declare const supportToolDefinition: {
|
|
8
9
|
name: string;
|
|
9
10
|
description: string;
|
|
@@ -20,12 +21,13 @@ export declare const supportToolDefinition: {
|
|
|
20
21
|
/**
|
|
21
22
|
* Handle a totalreclaw_support tool call.
|
|
22
23
|
*
|
|
23
|
-
* Returns static support information. No server calls needed
|
|
24
|
+
* Returns static support information. No server calls needed — `async` only
|
|
25
|
+
* for signature uniformity with the rest of the tool surface.
|
|
24
26
|
*/
|
|
25
|
-
export declare function handleSupport(
|
|
27
|
+
export declare function handleSupport(ctx: ToolContext, _args?: unknown): Promise<{
|
|
26
28
|
content: Array<{
|
|
27
29
|
type: string;
|
|
28
30
|
text: string;
|
|
29
31
|
}>;
|
|
30
|
-
}
|
|
32
|
+
}>;
|
|
31
33
|
//# sourceMappingURL=support.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"support.d.ts","sourceRoot":"","sources":["../../src/tools/support.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;
|
|
1
|
+
{"version":3,"file":"support.d.ts","sourceRoot":"","sources":["../../src/tools/support.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAG9C,eAAO,MAAM,qBAAqB;;;;;;;;;;;;CAYjC,CAAC;AAwCF;;;;;GAKG;AACH,wBAAsB,aAAa,CACjC,GAAG,EAAE,WAAW,EAChB,KAAK,CAAC,EAAE,OAAO,GACd,OAAO,CAAC;IAAE,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CAAE,CAAC,CAsB7D"}
|
package/dist/tools/support.js
CHANGED
|
@@ -39,14 +39,13 @@ const TROUBLESHOOTING = [
|
|
|
39
39
|
{
|
|
40
40
|
issue: 'Quota exceeded / cannot store more memories',
|
|
41
41
|
solution: 'Free tier has a monthly write limit. Use totalreclaw_status to check your remaining quota. ' +
|
|
42
|
-
'Upgrade to Pro via totalreclaw_upgrade for
|
|
43
|
-
'After upgrading, use totalreclaw_migrate to move existing memories from testnet to mainnet.',
|
|
42
|
+
'Upgrade to Pro via totalreclaw_upgrade for a higher monthly limit on Gnosis mainnet.',
|
|
44
43
|
},
|
|
45
44
|
{
|
|
46
|
-
issue: '
|
|
47
|
-
solution: '
|
|
48
|
-
'
|
|
49
|
-
'
|
|
45
|
+
issue: 'Pro tier not recognized after upgrade',
|
|
46
|
+
solution: 'All memories are stored on Gnosis mainnet regardless of tier, so nothing needs to move after ' +
|
|
47
|
+
'upgrading. The billing cache refreshes every 2 hours -- restart the MCP server to force a ' +
|
|
48
|
+
'refresh if your Pro tier is not yet recognized.',
|
|
50
49
|
},
|
|
51
50
|
{
|
|
52
51
|
issue: 'Import failed or memories not importing',
|
|
@@ -58,9 +57,11 @@ const TROUBLESHOOTING = [
|
|
|
58
57
|
/**
|
|
59
58
|
* Handle a totalreclaw_support tool call.
|
|
60
59
|
*
|
|
61
|
-
* Returns static support information. No server calls needed
|
|
60
|
+
* Returns static support information. No server calls needed — `async` only
|
|
61
|
+
* for signature uniformity with the rest of the tool surface.
|
|
62
62
|
*/
|
|
63
|
-
function handleSupport(
|
|
63
|
+
async function handleSupport(ctx, _args) {
|
|
64
|
+
const walletAddress = ctx.walletAddress ?? null;
|
|
64
65
|
const subject = walletAddress
|
|
65
66
|
? `TotalReclaw Support (wallet: ${walletAddress})`
|
|
66
67
|
: 'TotalReclaw Support';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"support.js","sourceRoot":"","sources":["../../src/tools/support.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;
|
|
1
|
+
{"version":3,"file":"support.js","sourceRoot":"","sources":["../../src/tools/support.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AA+DH,sCAyBC;AArFD,8CAAyD;AAE5C,QAAA,qBAAqB,GAAG;IACnC,IAAI,EAAE,qBAAqB;IAC3B,WAAW,EAAE,qCAAwB;IACrC,WAAW,EAAE;QACX,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE,EAAE;KACf;IACD,WAAW,EAAE;QACX,YAAY,EAAE,IAAI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 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared tool-handler contract for the TotalReclaw MCP server.
|
|
3
|
+
*
|
|
4
|
+
* Every `totalreclaw_*` tool handler takes the same two arguments:
|
|
5
|
+
* `(ctx: ToolContext, args: unknown)`. `ctx` is the dependency-injection
|
|
6
|
+
* bundle (self-hosted client, relay URL, auth key, wallet, …) assembled once
|
|
7
|
+
* by the dispatcher in `mcp/src/index.ts`; `args` is the raw tool input.
|
|
8
|
+
*
|
|
9
|
+
* Not every field is populated for every call — a handler reads only the
|
|
10
|
+
* fields it needs (e.g. the self-hosted storage handlers use `ctx.client`,
|
|
11
|
+
* the billing handlers use `ctx.serverUrl` + `ctx.authKeyHex`). This keeps a
|
|
12
|
+
* single predictable signature across the whole tool surface instead of the
|
|
13
|
+
* per-handler positional/options variance the server used to carry.
|
|
14
|
+
*/
|
|
15
|
+
import type { TotalReclaw } from '@totalreclaw/client';
|
|
16
|
+
export interface ToolContext {
|
|
17
|
+
/** Self-hosted (HTTP mode) client. Undefined in managed-service mode. */
|
|
18
|
+
client?: TotalReclaw;
|
|
19
|
+
/** Relay base URL for billing/account/upgrade calls. */
|
|
20
|
+
serverUrl?: string;
|
|
21
|
+
/** Hex-encoded auth key for relay `Authorization: Bearer` headers. */
|
|
22
|
+
authKeyHex?: string;
|
|
23
|
+
/** Smart Account address (managed service) — used for billing + support. */
|
|
24
|
+
walletAddress?: string | null;
|
|
25
|
+
/** Recovery-phrase hint (`first … last`) for the account tool. */
|
|
26
|
+
mnemonicHint?: string;
|
|
27
|
+
/** Lazily fetch the owner's on-chain fact count (account tool). */
|
|
28
|
+
getFactCount?: () => Promise<number>;
|
|
29
|
+
}
|
|
30
|
+
/** Standard MCP tool response envelope returned by every handler. */
|
|
31
|
+
export interface ToolResponse {
|
|
32
|
+
content: Array<{
|
|
33
|
+
type: string;
|
|
34
|
+
text: string;
|
|
35
|
+
}>;
|
|
36
|
+
isError?: boolean;
|
|
37
|
+
}
|
|
38
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/tools/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAEvD,MAAM,WAAW,WAAW;IAC1B,yEAAyE;IACzE,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,wDAAwD;IACxD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sEAAsE;IACtE,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,4EAA4E;IAC5E,aAAa,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B,kEAAkE;IAClE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,mEAAmE;IACnE,YAAY,CAAC,EAAE,MAAM,OAAO,CAAC,MAAM,CAAC,CAAC;CACtC;AAED,qEAAqE;AACrE,MAAM,WAAW,YAAY;IAC3B,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAC/C,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Shared tool-handler contract for the TotalReclaw MCP server.
|
|
4
|
+
*
|
|
5
|
+
* Every `totalreclaw_*` tool handler takes the same two arguments:
|
|
6
|
+
* `(ctx: ToolContext, args: unknown)`. `ctx` is the dependency-injection
|
|
7
|
+
* bundle (self-hosted client, relay URL, auth key, wallet, …) assembled once
|
|
8
|
+
* by the dispatcher in `mcp/src/index.ts`; `args` is the raw tool input.
|
|
9
|
+
*
|
|
10
|
+
* Not every field is populated for every call — a handler reads only the
|
|
11
|
+
* fields it needs (e.g. the self-hosted storage handlers use `ctx.client`,
|
|
12
|
+
* the billing handlers use `ctx.serverUrl` + `ctx.authKeyHex`). This keeps a
|
|
13
|
+
* single predictable signature across the whole tool surface instead of the
|
|
14
|
+
* per-handler positional/options variance the server used to carry.
|
|
15
|
+
*/
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
//# sourceMappingURL=types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/tools/types.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;GAaG"}
|
package/dist/tools/upgrade.d.ts
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
*
|
|
4
4
|
* Creates a Stripe checkout session for upgrading to Pro tier.
|
|
5
5
|
*/
|
|
6
|
+
import type { ToolContext } from './types.js';
|
|
6
7
|
export declare const upgradeToolDefinition: {
|
|
7
8
|
name: string;
|
|
8
9
|
description: string;
|
|
@@ -32,7 +33,7 @@ export interface CheckoutResponse {
|
|
|
32
33
|
* Creates a checkout session via the relay server and returns
|
|
33
34
|
* the checkout URL for the user to complete payment.
|
|
34
35
|
*/
|
|
35
|
-
export declare function handleUpgrade(
|
|
36
|
+
export declare function handleUpgrade(ctx: ToolContext, args: unknown): Promise<{
|
|
36
37
|
content: Array<{
|
|
37
38
|
type: string;
|
|
38
39
|
text: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"upgrade.d.ts","sourceRoot":"","sources":["../../src/tools/upgrade.ts"],"names":[],"mappings":"AAAA;;;;GAIG;
|
|
1
|
+
{"version":3,"file":"upgrade.d.ts","sourceRoot":"","sources":["../../src/tools/upgrade.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAI9C,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;CAkBjC,CAAC;AAEF,MAAM,WAAW,gBAAgB;IAC/B,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;;;;GAKG;AACH,wBAAsB,aAAa,CACjC,GAAG,EAAE,WAAW,EAChB,IAAI,EAAE,OAAO,GACZ,OAAO,CAAC;IAAE,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CAAE,CAAC,CAqE7D"}
|
package/dist/tools/upgrade.js
CHANGED
|
@@ -34,7 +34,9 @@ exports.upgradeToolDefinition = {
|
|
|
34
34
|
* Creates a checkout session via the relay server and returns
|
|
35
35
|
* the checkout URL for the user to complete payment.
|
|
36
36
|
*/
|
|
37
|
-
async function handleUpgrade(
|
|
37
|
+
async function handleUpgrade(ctx, args) {
|
|
38
|
+
const serverUrl = ctx.serverUrl ?? '';
|
|
39
|
+
const authKey = ctx.authKeyHex ?? '';
|
|
38
40
|
const input = args;
|
|
39
41
|
const walletAddress = input?.wallet_address;
|
|
40
42
|
if (!walletAddress || typeof walletAddress !== 'string') {
|
|
@@ -74,13 +76,13 @@ async function handleUpgrade(serverUrl, authKey, args) {
|
|
|
74
76
|
}],
|
|
75
77
|
};
|
|
76
78
|
}
|
|
77
|
-
const
|
|
79
|
+
const checkoutJson = (await response.json());
|
|
78
80
|
return {
|
|
79
81
|
content: [{
|
|
80
82
|
type: 'text',
|
|
81
83
|
text: JSON.stringify({
|
|
82
|
-
checkout_url:
|
|
83
|
-
message: `Open this URL to complete your upgrade to Pro: ${
|
|
84
|
+
checkout_url: checkoutJson.checkout_url,
|
|
85
|
+
message: `Open this URL to complete your upgrade to Pro: ${checkoutJson.checkout_url}`,
|
|
84
86
|
}),
|
|
85
87
|
}],
|
|
86
88
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"upgrade.js","sourceRoot":"","sources":["../../src/tools/upgrade.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;
|
|
1
|
+
{"version":3,"file":"upgrade.js","sourceRoot":"","sources":["../../src/tools/upgrade.ts"],"names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ACH,CAAC;SACH,CAAC;IACJ,CAAC;AACH,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@totalreclaw/mcp-server",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.4.0",
|
|
4
4
|
"description": "End-to-end encrypted memory for AI agents — portable, yours forever. MCP server with XChaCha20-Poly1305 E2EE, semantic search, import/export, and on-chain storage",
|
|
5
5
|
"homepage": "https://totalreclaw.xyz",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -39,9 +39,8 @@
|
|
|
39
39
|
"@noble/hashes": "^2.0.1",
|
|
40
40
|
"@scure/bip39": "^2.0.1",
|
|
41
41
|
"@totalreclaw/client": "^1.3.0",
|
|
42
|
-
"@totalreclaw/core": "^2.
|
|
42
|
+
"@totalreclaw/core": "^2.5.3",
|
|
43
43
|
"permissionless": "^0.3.4",
|
|
44
|
-
"porter-stemmer": "^0.9.1",
|
|
45
44
|
"tslib": "^2.8.1",
|
|
46
45
|
"viem": "^2.47.0",
|
|
47
46
|
"ws": "^8.18.3"
|
package/dist/subgraph/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/subgraph/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC"}
|
package/dist/subgraph/index.js
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./crypto.js"), exports);
|
|
18
|
-
__exportStar(require("./lsh.js"), exports);
|
|
19
|
-
__exportStar(require("./embedding.js"), exports);
|
|
20
|
-
__exportStar(require("./reranker.js"), exports);
|
|
21
|
-
__exportStar(require("./store.js"), exports);
|
|
22
|
-
__exportStar(require("./search.js"), exports);
|
|
23
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/subgraph/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8CAA4B;AAC5B,2CAAyB;AACzB,iDAA+B;AAC/B,gDAA8B;AAC9B,6CAA2B;AAC3B,8CAA4B"}
|
package/dist/tools/migrate.d.ts
DELETED
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* TotalReclaw MCP - Testnet-to-Mainnet Migration Tool
|
|
3
|
-
*
|
|
4
|
-
* Migrates encrypted memories from Base Sepolia (free tier testnet) to
|
|
5
|
-
* Gnosis mainnet (Pro tier) after a user upgrades.
|
|
6
|
-
*
|
|
7
|
-
* The encrypted data is chain-agnostic: same XChaCha20-Poly1305 ciphertext works
|
|
8
|
-
* on any chain. Smart Account addresses are deterministic (CREATE2), so
|
|
9
|
-
* the owner is the same on both chains. No re-encryption needed.
|
|
10
|
-
*
|
|
11
|
-
* Flow:
|
|
12
|
-
* 1. Verify user is Pro tier (via billing endpoint)
|
|
13
|
-
* 2. Fetch ALL active facts from testnet subgraph (paginated)
|
|
14
|
-
* 3. Fetch existing mainnet facts (by contentFp) for idempotency
|
|
15
|
-
* 4. Filter out facts that already exist on mainnet
|
|
16
|
-
* 5. Re-encode each fact as protobuf and batch-submit to mainnet via relay
|
|
17
|
-
* 6. Report progress and summary
|
|
18
|
-
*
|
|
19
|
-
* Safety:
|
|
20
|
-
* - Dry-run by default (confirm=false): shows preview without migrating
|
|
21
|
-
* - Testnet facts are never deleted (they remain as a backup)
|
|
22
|
-
* - Idempotent: skips facts that already exist on mainnet (by contentFp)
|
|
23
|
-
* - Handles partial failures gracefully (reports per-batch results)
|
|
24
|
-
*/
|
|
25
|
-
export declare const migrateToolDefinition: {
|
|
26
|
-
name: string;
|
|
27
|
-
description: string;
|
|
28
|
-
inputSchema: {
|
|
29
|
-
type: string;
|
|
30
|
-
properties: {
|
|
31
|
-
confirm: {
|
|
32
|
-
type: string;
|
|
33
|
-
description: string;
|
|
34
|
-
default: boolean;
|
|
35
|
-
};
|
|
36
|
-
};
|
|
37
|
-
};
|
|
38
|
-
annotations: {
|
|
39
|
-
readOnlyHint: boolean;
|
|
40
|
-
destructiveHint: boolean;
|
|
41
|
-
idempotentHint: boolean;
|
|
42
|
-
};
|
|
43
|
-
};
|
|
44
|
-
export interface SubgraphFactFull {
|
|
45
|
-
id: string;
|
|
46
|
-
owner: string;
|
|
47
|
-
encryptedBlob: string;
|
|
48
|
-
encryptedEmbedding: string | null;
|
|
49
|
-
decayScore: string;
|
|
50
|
-
isActive: boolean;
|
|
51
|
-
contentFp: string;
|
|
52
|
-
source: string;
|
|
53
|
-
agentId: string;
|
|
54
|
-
version: number;
|
|
55
|
-
timestamp: string;
|
|
56
|
-
}
|
|
57
|
-
export interface MigrationResult {
|
|
58
|
-
success: boolean;
|
|
59
|
-
mode: 'dry_run' | 'executed';
|
|
60
|
-
testnet_facts: number;
|
|
61
|
-
already_on_mainnet: number;
|
|
62
|
-
to_migrate: number;
|
|
63
|
-
migrated: number;
|
|
64
|
-
failed_batches: number;
|
|
65
|
-
batch_results: Array<{
|
|
66
|
-
batch_number: number;
|
|
67
|
-
size: number;
|
|
68
|
-
success: boolean;
|
|
69
|
-
tx_hash?: string;
|
|
70
|
-
error?: string;
|
|
71
|
-
}>;
|
|
72
|
-
message: string;
|
|
73
|
-
}
|
|
74
|
-
export declare function fetchAllFactsFromSubgraph(subgraphUrl: string, owner: string, authKeyHex?: string): Promise<SubgraphFactFull[]>;
|
|
75
|
-
export declare function fetchMainnetContentFps(subgraphUrl: string, owner: string, authKeyHex?: string): Promise<Set<string>>;
|
|
76
|
-
export declare function checkBillingTier(serverUrl: string, walletAddress: string, authKeyHex: string): Promise<{
|
|
77
|
-
tier: string;
|
|
78
|
-
error?: string;
|
|
79
|
-
}>;
|
|
80
|
-
/**
|
|
81
|
-
* Fetch blind index hashes for a list of fact IDs from the subgraph.
|
|
82
|
-
* Returns a Map from fact ID to array of blind index hashes.
|
|
83
|
-
*
|
|
84
|
-
* Processes fact IDs in chunks of 50 to avoid query limits.
|
|
85
|
-
* Each fact may have ~25-35 blind indices (20 LSH + word indices).
|
|
86
|
-
*/
|
|
87
|
-
export declare function fetchBlindIndicesForFacts(subgraphUrl: string, factIds: string[], authKeyHex: string): Promise<Map<string, string[]>>;
|
|
88
|
-
//# sourceMappingURL=migrate.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"migrate.d.ts","sourceRoot":"","sources":["../../src/tools/migrate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAKH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;CAkBjC,CAAC;AAMF,MAAM,WAAW,gBAAgB;IAC/B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,aAAa,EAAE,MAAM,CAAC;IACtB,kBAAk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