@varun-ai07/covenant-mcp 1.0.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 +1078 -0
- package/dist/cli.d.ts +3 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +195 -0
- package/dist/cli.js.map +1 -0
- package/dist/colors.d.ts +14 -0
- package/dist/colors.d.ts.map +1 -0
- package/dist/colors.js +14 -0
- package/dist/colors.js.map +1 -0
- package/dist/config.d.ts +396 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +191 -0
- package/dist/config.js.map +1 -0
- package/dist/handlers/transactions.d.ts +5 -0
- package/dist/handlers/transactions.d.ts.map +1 -0
- package/dist/handlers/transactions.js +82 -0
- package/dist/handlers/transactions.js.map +1 -0
- package/dist/handlers/wallet.d.ts +24 -0
- package/dist/handlers/wallet.d.ts.map +1 -0
- package/dist/handlers/wallet.js +264 -0
- package/dist/handlers/wallet.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +49 -0
- package/dist/index.js.map +1 -0
- package/dist/logger.d.ts +11 -0
- package/dist/logger.d.ts.map +1 -0
- package/dist/logger.js +31 -0
- package/dist/logger.js.map +1 -0
- package/dist/postinstall.d.ts +3 -0
- package/dist/postinstall.d.ts.map +1 -0
- package/dist/postinstall.js +38 -0
- package/dist/postinstall.js.map +1 -0
- package/dist/schemas.d.ts +48 -0
- package/dist/schemas.d.ts.map +1 -0
- package/dist/schemas.js +114 -0
- package/dist/schemas.js.map +1 -0
- package/dist/server.d.ts +23 -0
- package/dist/server.d.ts.map +1 -0
- package/dist/server.js +51 -0
- package/dist/server.js.map +1 -0
- package/dist/tools/batches.d.ts +3 -0
- package/dist/tools/batches.d.ts.map +1 -0
- package/dist/tools/batches.js +167 -0
- package/dist/tools/batches.js.map +1 -0
- package/dist/tools/collectives.d.ts +3 -0
- package/dist/tools/collectives.d.ts.map +1 -0
- package/dist/tools/collectives.js +168 -0
- package/dist/tools/collectives.js.map +1 -0
- package/dist/tools/disputes.d.ts +3 -0
- package/dist/tools/disputes.d.ts.map +1 -0
- package/dist/tools/disputes.js +129 -0
- package/dist/tools/disputes.js.map +1 -0
- package/dist/tools/escrow.d.ts +3 -0
- package/dist/tools/escrow.d.ts.map +1 -0
- package/dist/tools/escrow.js +238 -0
- package/dist/tools/escrow.js.map +1 -0
- package/dist/tools/insurance.d.ts +3 -0
- package/dist/tools/insurance.d.ts.map +1 -0
- package/dist/tools/insurance.js +101 -0
- package/dist/tools/insurance.js.map +1 -0
- package/dist/tools/market.d.ts +3 -0
- package/dist/tools/market.d.ts.map +1 -0
- package/dist/tools/market.js +303 -0
- package/dist/tools/market.js.map +1 -0
- package/dist/tools/protocol.d.ts +3 -0
- package/dist/tools/protocol.d.ts.map +1 -0
- package/dist/tools/protocol.js +121 -0
- package/dist/tools/protocol.js.map +1 -0
- package/dist/tools/receipts.d.ts +3 -0
- package/dist/tools/receipts.d.ts.map +1 -0
- package/dist/tools/receipts.js +88 -0
- package/dist/tools/receipts.js.map +1 -0
- package/dist/tools/registry.d.ts +3 -0
- package/dist/tools/registry.d.ts.map +1 -0
- package/dist/tools/registry.js +136 -0
- package/dist/tools/registry.js.map +1 -0
- package/dist/transports/http.d.ts +3 -0
- package/dist/transports/http.d.ts.map +1 -0
- package/dist/transports/http.js +121 -0
- package/dist/transports/http.js.map +1 -0
- package/dist/transports/stdio.d.ts +7 -0
- package/dist/transports/stdio.d.ts.map +1 -0
- package/dist/transports/stdio.js +9 -0
- package/dist/transports/stdio.js.map +1 -0
- package/dist/types.d.ts +89 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +24 -0
- package/dist/types.js.map +1 -0
- package/package.json +70 -0
package/dist/cli.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":""}
|
package/dist/cli.js
ADDED
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* COVENANT MCP CLI
|
|
4
|
+
*
|
|
5
|
+
* One-command installation for Claude Code and MCP-compatible tools.
|
|
6
|
+
*
|
|
7
|
+
* Usage:
|
|
8
|
+
* npx @covenant/mcp add - Add to Claude Code config
|
|
9
|
+
* npx @covenant/mcp remove - Remove from Claude Code config
|
|
10
|
+
* npx @covenant/mcp status - Check installation status
|
|
11
|
+
* npx @covenant/mcp start - Start the MCP server
|
|
12
|
+
*/
|
|
13
|
+
import { spawn, execSync } from "child_process";
|
|
14
|
+
import { existsSync, readFileSync, writeFileSync, mkdirSync } from "fs";
|
|
15
|
+
import { homedir, platform } from "os";
|
|
16
|
+
import { join } from "path";
|
|
17
|
+
import { fileURLToPath } from "url";
|
|
18
|
+
import { dirname } from "path";
|
|
19
|
+
const __filename = fileURLToPath(import.meta.url);
|
|
20
|
+
const __dirname = dirname(__filename);
|
|
21
|
+
// Colors for terminal output
|
|
22
|
+
const colors = {
|
|
23
|
+
reset: "\x1b[0m",
|
|
24
|
+
green: "\x1b[32m",
|
|
25
|
+
yellow: "\x1b[33m",
|
|
26
|
+
blue: "\x1b[34m",
|
|
27
|
+
red: "\x1b[31m",
|
|
28
|
+
cyan: "\x1b[36m",
|
|
29
|
+
bold: "\x1b[1m",
|
|
30
|
+
};
|
|
31
|
+
function log(message, color = colors.reset) {
|
|
32
|
+
console.log(`${color}${message}${colors.reset}`);
|
|
33
|
+
}
|
|
34
|
+
function getConfigPath() {
|
|
35
|
+
const os = platform();
|
|
36
|
+
if (os === "win32") {
|
|
37
|
+
return join(process.env.APPDATA || "", "Claude", "claude_desktop_config.json");
|
|
38
|
+
}
|
|
39
|
+
return join(homedir(), ".claude", "claude_desktop_config.json");
|
|
40
|
+
}
|
|
41
|
+
function getServerPath() {
|
|
42
|
+
return join(__dirname, "index.js");
|
|
43
|
+
}
|
|
44
|
+
function readConfig() {
|
|
45
|
+
const configPath = getConfigPath();
|
|
46
|
+
if (!existsSync(configPath)) {
|
|
47
|
+
return { mcpServers: {} };
|
|
48
|
+
}
|
|
49
|
+
try {
|
|
50
|
+
return JSON.parse(readFileSync(configPath, "utf-8"));
|
|
51
|
+
}
|
|
52
|
+
catch (e) {
|
|
53
|
+
return { mcpServers: {} };
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
function writeConfig(config) {
|
|
57
|
+
const configPath = getConfigPath();
|
|
58
|
+
const configDir = dirname(configPath);
|
|
59
|
+
if (!existsSync(configDir)) {
|
|
60
|
+
mkdirSync(configDir, { recursive: true });
|
|
61
|
+
}
|
|
62
|
+
writeFileSync(configPath, JSON.stringify(config, null, 2));
|
|
63
|
+
}
|
|
64
|
+
function addCommand() {
|
|
65
|
+
log("\n COVENANT MCP Installer\n", colors.bold + colors.cyan);
|
|
66
|
+
const serverPath = getServerPath();
|
|
67
|
+
const configPath = getConfigPath();
|
|
68
|
+
log(` Server path: ${serverPath}`, colors.blue);
|
|
69
|
+
log(` Config path: ${configPath}`, colors.blue);
|
|
70
|
+
log("");
|
|
71
|
+
// Check if server is built
|
|
72
|
+
if (!existsSync(serverPath)) {
|
|
73
|
+
log(" ✗ Server not built. Running build...", colors.yellow);
|
|
74
|
+
try {
|
|
75
|
+
execSync("npm run build", { cwd: __dirname, stdio: "inherit" });
|
|
76
|
+
}
|
|
77
|
+
catch (e) {
|
|
78
|
+
log(" ✗ Build failed. Please run 'npm run build' in the mcp directory.", colors.red);
|
|
79
|
+
process.exit(1);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
const config = readConfig();
|
|
83
|
+
// Add covenant server
|
|
84
|
+
config.mcpServers = config.mcpServers || {};
|
|
85
|
+
config.mcpServers.covenant = {
|
|
86
|
+
command: "node",
|
|
87
|
+
args: [serverPath],
|
|
88
|
+
};
|
|
89
|
+
writeConfig(config);
|
|
90
|
+
log(" ✓ COVENANT MCP added to Claude Code configuration", colors.green);
|
|
91
|
+
log("");
|
|
92
|
+
log(" Available tools (39):", colors.bold);
|
|
93
|
+
log(" • Agent Registry: register_agent, get_agent, find_workers", colors.reset);
|
|
94
|
+
log(" • Task Escrow: create_task, get_task, submit_work, verify_task, dispute_task", colors.reset);
|
|
95
|
+
log(" • Open Market: post_open_task, submit_bid, select_worker, ...", colors.reset);
|
|
96
|
+
log(" • And 25+ more blockchain interaction tools", colors.reset);
|
|
97
|
+
log("");
|
|
98
|
+
log(" Next steps:", colors.bold);
|
|
99
|
+
log(" 1. Set environment variables in mcp/.env:", colors.yellow);
|
|
100
|
+
log(" PRIVATE_KEY=0x...", colors.reset);
|
|
101
|
+
log(" BASE_SEPOLIA_RPC_URL=https://sepolia.base.org", colors.reset);
|
|
102
|
+
log("");
|
|
103
|
+
log(" 2. Restart Claude Code", colors.yellow);
|
|
104
|
+
log("");
|
|
105
|
+
log(" Contract Addresses (Base Sepolia):", colors.bold);
|
|
106
|
+
log(" AgentRegistry: 0x3e4a9013Ec6315eF0e13B4f768e07cf43c6c3369", colors.cyan);
|
|
107
|
+
log(" TaskEscrow: 0xb2a2b7f046fa82A020B3008A71E61d16603BAa05", colors.cyan);
|
|
108
|
+
log("");
|
|
109
|
+
}
|
|
110
|
+
function removeCommand() {
|
|
111
|
+
log("\n Removing COVENANT MCP...\n", colors.yellow);
|
|
112
|
+
const config = readConfig();
|
|
113
|
+
if (config.mcpServers?.covenant) {
|
|
114
|
+
delete config.mcpServers.covenant;
|
|
115
|
+
writeConfig(config);
|
|
116
|
+
log(" ✓ COVENANT MCP removed from Claude Code configuration\n", colors.green);
|
|
117
|
+
}
|
|
118
|
+
else {
|
|
119
|
+
log(" ✗ COVENANT MCP was not installed\n", colors.yellow);
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
function statusCommand() {
|
|
123
|
+
log("\n COVENANT MCP Status\n", colors.bold + colors.cyan);
|
|
124
|
+
const config = readConfig();
|
|
125
|
+
const isInstalled = !!config.mcpServers?.covenant;
|
|
126
|
+
log(` Installed: ${isInstalled ? "✓ Yes" : "✗ No"}`, isInstalled ? colors.green : colors.red);
|
|
127
|
+
if (isInstalled) {
|
|
128
|
+
const serverPath = config.mcpServers.covenant.args?.[0];
|
|
129
|
+
log(` Server: ${serverPath}`, colors.blue);
|
|
130
|
+
log(` Built: ${existsSync(serverPath) ? "✓ Yes" : "✗ No"}`, existsSync(serverPath) ? colors.green : colors.red);
|
|
131
|
+
}
|
|
132
|
+
log("");
|
|
133
|
+
}
|
|
134
|
+
function startCommand() {
|
|
135
|
+
log("\n Starting COVENANT MCP Server...\n", colors.cyan);
|
|
136
|
+
const serverPath = getServerPath();
|
|
137
|
+
if (!existsSync(serverPath)) {
|
|
138
|
+
log(" ✗ Server not built. Run 'npm run build' first.\n", colors.red);
|
|
139
|
+
process.exit(1);
|
|
140
|
+
}
|
|
141
|
+
const child = spawn("node", [serverPath, "--stdio"], {
|
|
142
|
+
stdio: "inherit",
|
|
143
|
+
});
|
|
144
|
+
child.on("error", (error) => {
|
|
145
|
+
log(` ✗ Error: ${error.message}`, colors.red);
|
|
146
|
+
});
|
|
147
|
+
}
|
|
148
|
+
function helpCommand() {
|
|
149
|
+
log(`
|
|
150
|
+
${colors.bold}COVENANT MCP CLI${colors.reset}
|
|
151
|
+
|
|
152
|
+
${colors.cyan}Usage:${colors.reset}
|
|
153
|
+
npx @covenant/mcp add Add to Claude Code configuration
|
|
154
|
+
npx @covenant/mcp remove Remove from Claude Code configuration
|
|
155
|
+
npx @covenant/mcp status Check installation status
|
|
156
|
+
npx @covenant/mcp start Start the MCP server manually
|
|
157
|
+
|
|
158
|
+
${colors.cyan}Environment Variables (mcp/.env):${colors.reset}
|
|
159
|
+
PRIVATE_KEY Wallet private key for signing transactions
|
|
160
|
+
BASE_SEPOLIA_RPC_URL RPC endpoint (default: https://sepolia.base.org)
|
|
161
|
+
MCP_API_KEY API key for HTTP mode
|
|
162
|
+
MCP_HTTP_PORT HTTP server port (default: 3001)
|
|
163
|
+
|
|
164
|
+
${colors.cyan}Documentation:${colors.reset}
|
|
165
|
+
https://github.com/Varun-ai07/COVENANT
|
|
166
|
+
|
|
167
|
+
`);
|
|
168
|
+
}
|
|
169
|
+
// Main CLI
|
|
170
|
+
const command = process.argv[2] || "help";
|
|
171
|
+
switch (command) {
|
|
172
|
+
case "add":
|
|
173
|
+
case "install":
|
|
174
|
+
addCommand();
|
|
175
|
+
break;
|
|
176
|
+
case "remove":
|
|
177
|
+
case "uninstall":
|
|
178
|
+
removeCommand();
|
|
179
|
+
break;
|
|
180
|
+
case "status":
|
|
181
|
+
case "check":
|
|
182
|
+
statusCommand();
|
|
183
|
+
break;
|
|
184
|
+
case "start":
|
|
185
|
+
case "run":
|
|
186
|
+
startCommand();
|
|
187
|
+
break;
|
|
188
|
+
case "help":
|
|
189
|
+
case "--help":
|
|
190
|
+
case "-h":
|
|
191
|
+
default:
|
|
192
|
+
helpCommand();
|
|
193
|
+
break;
|
|
194
|
+
}
|
|
195
|
+
//# sourceMappingURL=cli.js.map
|
package/dist/cli.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AACA;;;;;;;;;;GAUG;AACH,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAChD,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,IAAI,CAAC;AACxE,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,IAAI,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,aAAa,EAAE,MAAM,KAAK,CAAC;AACpC,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAE/B,MAAM,UAAU,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAClD,MAAM,SAAS,GAAG,OAAO,CAAC,UA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a,EAAE,CAAC;QAChB,MAAM;IACR,KAAK,QAAQ,CAAC;IACd,KAAK,OAAO;QACV,aAAa,EAAE,CAAC;QAChB,MAAM;IACR,KAAK,OAAO,CAAC;IACb,KAAK,KAAK;QACR,YAAY,EAAE,CAAC;QACf,MAAM;IACR,KAAK,MAAM,CAAC;IACZ,KAAK,QAAQ,CAAC;IACd,KAAK,IAAI,CAAC;IACV;QACE,WAAW,EAAE,CAAC;QACd,MAAM;AACV,CAAC"}
|
package/dist/colors.d.ts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Terminal colors utility
|
|
3
|
+
*/
|
|
4
|
+
export declare const colors: {
|
|
5
|
+
reset: string;
|
|
6
|
+
green: string;
|
|
7
|
+
yellow: string;
|
|
8
|
+
blue: string;
|
|
9
|
+
red: string;
|
|
10
|
+
cyan: string;
|
|
11
|
+
bold: string;
|
|
12
|
+
};
|
|
13
|
+
export declare const reset: string, green: string, yellow: string, blue: string, red: string, cyan: string, bold: string;
|
|
14
|
+
//# sourceMappingURL=colors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"colors.d.ts","sourceRoot":"","sources":["../src/colors.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,eAAO,MAAM,MAAM;;;;;;;;CAQlB,CAAC;AAEF,eAAO,MAAQ,KAAK,UAAE,KAAK,UAAE,MAAM,UAAE,IAAI,UAAE,GAAG,UAAE,IAAI,UAAE,IAAI,QAAW,CAAC"}
|
package/dist/colors.js
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Terminal colors utility
|
|
3
|
+
*/
|
|
4
|
+
export const colors = {
|
|
5
|
+
reset: "\x1b[0m",
|
|
6
|
+
green: "\x1b[32m",
|
|
7
|
+
yellow: "\x1b[33m",
|
|
8
|
+
blue: "\x1b[34m",
|
|
9
|
+
red: "\x1b[31m",
|
|
10
|
+
cyan: "\x1b[36m",
|
|
11
|
+
bold: "\x1b[1m",
|
|
12
|
+
};
|
|
13
|
+
export const { reset, green, yellow, blue, red, cyan, bold } = colors;
|
|
14
|
+
//# sourceMappingURL=colors.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"colors.js","sourceRoot":"","sources":["../src/colors.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG;IACpB,KAAK,EAAE,SAAS;IAChB,KAAK,EAAE,UAAU;IACjB,MAAM,EAAE,UAAU;IAClB,IAAI,EAAE,UAAU;IAChB,GAAG,EAAE,UAAU;IACf,IAAI,EAAE,UAAU;IAChB,IAAI,EAAE,SAAS;CAChB,CAAC;AAEF,MAAM,CAAC,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,MAAM,CAAC"}
|
package/dist/config.d.ts
ADDED
|
@@ -0,0 +1,396 @@
|
|
|
1
|
+
import { type Address } from "viem";
|
|
2
|
+
import type { WalletMode, ContractConfig } from "./types.js";
|
|
3
|
+
export declare const RPC_URL: string;
|
|
4
|
+
export declare const CHAIN: {
|
|
5
|
+
blockExplorers?: {
|
|
6
|
+
[key: string]: {
|
|
7
|
+
name: string;
|
|
8
|
+
url: string;
|
|
9
|
+
apiUrl?: string | undefined;
|
|
10
|
+
};
|
|
11
|
+
default: {
|
|
12
|
+
name: string;
|
|
13
|
+
url: string;
|
|
14
|
+
apiUrl?: string | undefined;
|
|
15
|
+
};
|
|
16
|
+
} | undefined | undefined;
|
|
17
|
+
blockTime?: number | undefined | undefined;
|
|
18
|
+
contracts?: {
|
|
19
|
+
[x: string]: import("viem").ChainContract | {
|
|
20
|
+
[sourceId: number]: import("viem").ChainContract | undefined;
|
|
21
|
+
} | undefined;
|
|
22
|
+
ensRegistry?: import("viem").ChainContract | undefined;
|
|
23
|
+
ensUniversalResolver?: import("viem").ChainContract | undefined;
|
|
24
|
+
multicall3?: import("viem").ChainContract | undefined;
|
|
25
|
+
erc6492Verifier?: import("viem").ChainContract | undefined;
|
|
26
|
+
} | undefined;
|
|
27
|
+
ensTlds?: readonly string[] | undefined;
|
|
28
|
+
id: 31337;
|
|
29
|
+
name: "Hardhat Local";
|
|
30
|
+
nativeCurrency: {
|
|
31
|
+
readonly decimals: 18;
|
|
32
|
+
readonly name: "Ether";
|
|
33
|
+
readonly symbol: "ETH";
|
|
34
|
+
};
|
|
35
|
+
experimental_preconfirmationTime?: number | undefined | undefined;
|
|
36
|
+
rpcUrls: {
|
|
37
|
+
readonly default: {
|
|
38
|
+
readonly http: readonly ["http://127.0.0.1:8545"];
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
sourceId?: number | undefined | undefined;
|
|
42
|
+
testnet?: boolean | undefined | undefined;
|
|
43
|
+
custom?: Record<string, unknown> | undefined;
|
|
44
|
+
extendSchema?: Record<string, unknown> | undefined;
|
|
45
|
+
fees?: import("viem").ChainFees<undefined> | undefined;
|
|
46
|
+
formatters?: undefined;
|
|
47
|
+
prepareTransactionRequest?: ((args: import("viem").PrepareTransactionRequestParameters, options: {
|
|
48
|
+
phase: "beforeFillTransaction" | "beforeFillParameters" | "afterFillParameters";
|
|
49
|
+
}) => Promise<import("viem").PrepareTransactionRequestParameters>) | [fn: ((args: import("viem").PrepareTransactionRequestParameters, options: {
|
|
50
|
+
phase: "beforeFillTransaction" | "beforeFillParameters" | "afterFillParameters";
|
|
51
|
+
}) => Promise<import("viem").PrepareTransactionRequestParameters>) | undefined, options: {
|
|
52
|
+
runAt: readonly ("beforeFillTransaction" | "beforeFillParameters" | "afterFillParameters")[];
|
|
53
|
+
}] | undefined;
|
|
54
|
+
serializers?: import("viem").ChainSerializers<undefined, import("viem").TransactionSerializable> | undefined;
|
|
55
|
+
verifyHash?: ((client: import("viem").Client, parameters: import("viem").VerifyHashActionParameters) => Promise<import("viem").VerifyHashActionReturnType>) | undefined;
|
|
56
|
+
} | {
|
|
57
|
+
blockExplorers: {
|
|
58
|
+
readonly default: {
|
|
59
|
+
readonly name: "Basescan";
|
|
60
|
+
readonly url: "https://sepolia.basescan.org";
|
|
61
|
+
readonly apiUrl: "https://api-sepolia.basescan.org/api";
|
|
62
|
+
};
|
|
63
|
+
};
|
|
64
|
+
blockTime: 2000;
|
|
65
|
+
contracts: {
|
|
66
|
+
readonly disputeGameFactory: {
|
|
67
|
+
readonly 11155111: {
|
|
68
|
+
readonly address: "0xd6E6dBf4F7EA0ac412fD8b65ED297e64BB7a06E1";
|
|
69
|
+
};
|
|
70
|
+
};
|
|
71
|
+
readonly l2OutputOracle: {
|
|
72
|
+
readonly 11155111: {
|
|
73
|
+
readonly address: "0x84457ca9D0163FbC4bbfe4Dfbb20ba46e48DF254";
|
|
74
|
+
};
|
|
75
|
+
};
|
|
76
|
+
readonly portal: {
|
|
77
|
+
readonly 11155111: {
|
|
78
|
+
readonly address: "0x49f53e41452c74589e85ca1677426ba426459e85";
|
|
79
|
+
readonly blockCreated: 4446677;
|
|
80
|
+
};
|
|
81
|
+
};
|
|
82
|
+
readonly l1StandardBridge: {
|
|
83
|
+
readonly 11155111: {
|
|
84
|
+
readonly address: "0xfd0Bf71F60660E2f608ed56e1659C450eB113120";
|
|
85
|
+
readonly blockCreated: 4446677;
|
|
86
|
+
};
|
|
87
|
+
};
|
|
88
|
+
readonly multicall3: {
|
|
89
|
+
readonly address: "0xca11bde05977b3631167028862be2a173976ca11";
|
|
90
|
+
readonly blockCreated: 1059647;
|
|
91
|
+
};
|
|
92
|
+
readonly gasPriceOracle: {
|
|
93
|
+
readonly address: "0x420000000000000000000000000000000000000F";
|
|
94
|
+
};
|
|
95
|
+
readonly l1Block: {
|
|
96
|
+
readonly address: "0x4200000000000000000000000000000000000015";
|
|
97
|
+
};
|
|
98
|
+
readonly l2CrossDomainMessenger: {
|
|
99
|
+
readonly address: "0x4200000000000000000000000000000000000007";
|
|
100
|
+
};
|
|
101
|
+
readonly l2Erc721Bridge: {
|
|
102
|
+
readonly address: "0x4200000000000000000000000000000000000014";
|
|
103
|
+
};
|
|
104
|
+
readonly l2StandardBridge: {
|
|
105
|
+
readonly address: "0x4200000000000000000000000000000000000010";
|
|
106
|
+
};
|
|
107
|
+
readonly l2ToL1MessagePasser: {
|
|
108
|
+
readonly address: "0x4200000000000000000000000000000000000016";
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
ensTlds?: readonly string[] | undefined;
|
|
112
|
+
id: 84532;
|
|
113
|
+
name: "Base Sepolia";
|
|
114
|
+
nativeCurrency: {
|
|
115
|
+
readonly name: "Sepolia Ether";
|
|
116
|
+
readonly symbol: "ETH";
|
|
117
|
+
readonly decimals: 18;
|
|
118
|
+
};
|
|
119
|
+
experimental_preconfirmationTime?: number | undefined | undefined;
|
|
120
|
+
rpcUrls: {
|
|
121
|
+
readonly default: {
|
|
122
|
+
readonly http: readonly ["https://sepolia.base.org"];
|
|
123
|
+
};
|
|
124
|
+
};
|
|
125
|
+
sourceId: 11155111;
|
|
126
|
+
testnet: true;
|
|
127
|
+
custom?: Record<string, unknown> | undefined;
|
|
128
|
+
extendSchema?: Record<string, unknown> | undefined;
|
|
129
|
+
fees?: import("viem").ChainFees<undefined> | undefined;
|
|
130
|
+
formatters: {
|
|
131
|
+
readonly block: {
|
|
132
|
+
exclude: [] | undefined;
|
|
133
|
+
format: (args: import("viem/chains").OpStackRpcBlock, action?: string | undefined) => {
|
|
134
|
+
baseFeePerGas: bigint | null;
|
|
135
|
+
blobGasUsed: bigint;
|
|
136
|
+
difficulty: bigint;
|
|
137
|
+
excessBlobGas: bigint;
|
|
138
|
+
extraData: import("viem").Hex;
|
|
139
|
+
gasLimit: bigint;
|
|
140
|
+
gasUsed: bigint;
|
|
141
|
+
hash: `0x${string}` | null;
|
|
142
|
+
logsBloom: `0x${string}` | null;
|
|
143
|
+
miner: import("abitype").Address;
|
|
144
|
+
mixHash: import("viem").Hash;
|
|
145
|
+
nonce: `0x${string}` | null;
|
|
146
|
+
number: bigint | null;
|
|
147
|
+
parentBeaconBlockRoot?: `0x${string}` | undefined;
|
|
148
|
+
parentHash: import("viem").Hash;
|
|
149
|
+
receiptsRoot: import("viem").Hex;
|
|
150
|
+
sealFields: import("viem").Hex[];
|
|
151
|
+
sha3Uncles: import("viem").Hash;
|
|
152
|
+
size: bigint;
|
|
153
|
+
stateRoot: import("viem").Hash;
|
|
154
|
+
timestamp: bigint;
|
|
155
|
+
totalDifficulty: bigint | null;
|
|
156
|
+
transactions: `0x${string}`[] | import("viem/chains").OpStackTransaction<boolean>[];
|
|
157
|
+
transactionsRoot: import("viem").Hash;
|
|
158
|
+
uncles: import("viem").Hash[];
|
|
159
|
+
withdrawals?: import("viem").Withdrawal[] | undefined | undefined;
|
|
160
|
+
withdrawalsRoot?: `0x${string}` | undefined;
|
|
161
|
+
} & {};
|
|
162
|
+
type: "block";
|
|
163
|
+
};
|
|
164
|
+
readonly transaction: {
|
|
165
|
+
exclude: [] | undefined;
|
|
166
|
+
format: (args: import("viem/chains").OpStackRpcTransaction, action?: string | undefined) => ({
|
|
167
|
+
blockHash: `0x${string}` | null;
|
|
168
|
+
blockNumber: bigint | null;
|
|
169
|
+
blockTimestamp?: bigint | undefined;
|
|
170
|
+
from: import("abitype").Address;
|
|
171
|
+
gas: bigint;
|
|
172
|
+
hash: import("viem").Hash;
|
|
173
|
+
input: import("viem").Hex;
|
|
174
|
+
nonce: number;
|
|
175
|
+
r: import("viem").Hex;
|
|
176
|
+
s: import("viem").Hex;
|
|
177
|
+
to: import("abitype").Address | null;
|
|
178
|
+
transactionIndex: number | null;
|
|
179
|
+
typeHex: import("viem").Hex | null;
|
|
180
|
+
v: bigint;
|
|
181
|
+
value: bigint;
|
|
182
|
+
yParity: number;
|
|
183
|
+
gasPrice?: undefined | undefined;
|
|
184
|
+
maxFeePerBlobGas?: undefined | undefined;
|
|
185
|
+
maxFeePerGas: bigint;
|
|
186
|
+
maxPriorityFeePerGas: bigint;
|
|
187
|
+
isSystemTx?: boolean;
|
|
188
|
+
mint?: bigint | undefined | undefined;
|
|
189
|
+
sourceHash: import("viem").Hex;
|
|
190
|
+
type: "deposit";
|
|
191
|
+
} | {
|
|
192
|
+
r: import("viem").Hex;
|
|
193
|
+
s: import("viem").Hex;
|
|
194
|
+
v: bigint;
|
|
195
|
+
to: import("abitype").Address | null;
|
|
196
|
+
from: import("abitype").Address;
|
|
197
|
+
gas: bigint;
|
|
198
|
+
nonce: number;
|
|
199
|
+
value: bigint;
|
|
200
|
+
blockHash: `0x${string}` | null;
|
|
201
|
+
blockNumber: bigint | null;
|
|
202
|
+
blockTimestamp?: bigint | undefined;
|
|
203
|
+
hash: import("viem").Hash;
|
|
204
|
+
input: import("viem").Hex;
|
|
205
|
+
transactionIndex: number | null;
|
|
206
|
+
typeHex: import("viem").Hex | null;
|
|
207
|
+
accessList?: undefined | undefined;
|
|
208
|
+
authorizationList?: undefined | undefined;
|
|
209
|
+
blobVersionedHashes?: undefined | undefined;
|
|
210
|
+
chainId?: number | undefined;
|
|
211
|
+
yParity?: undefined | undefined;
|
|
212
|
+
type: "legacy";
|
|
213
|
+
gasPrice: bigint;
|
|
214
|
+
maxFeePerBlobGas?: undefined | undefined;
|
|
215
|
+
maxFeePerGas?: undefined | undefined;
|
|
216
|
+
maxPriorityFeePerGas?: undefined | undefined;
|
|
217
|
+
isSystemTx?: undefined | undefined;
|
|
218
|
+
mint?: undefined | undefined;
|
|
219
|
+
sourceHash?: undefined | undefined;
|
|
220
|
+
} | {
|
|
221
|
+
blockHash: `0x${string}` | null;
|
|
222
|
+
blockNumber: bigint | null;
|
|
223
|
+
blockTimestamp?: bigint | undefined;
|
|
224
|
+
from: import("abitype").Address;
|
|
225
|
+
gas: bigint;
|
|
226
|
+
hash: import("viem").Hash;
|
|
227
|
+
input: import("viem").Hex;
|
|
228
|
+
nonce: number;
|
|
229
|
+
r: import("viem").Hex;
|
|
230
|
+
s: import("viem").Hex;
|
|
231
|
+
to: import("abitype").Address | null;
|
|
232
|
+
transactionIndex: number | null;
|
|
233
|
+
typeHex: import("viem").Hex | null;
|
|
234
|
+
v: bigint;
|
|
235
|
+
value: bigint;
|
|
236
|
+
yParity: number;
|
|
237
|
+
accessList: import("viem").AccessList;
|
|
238
|
+
authorizationList?: undefined | undefined;
|
|
239
|
+
blobVersionedHashes?: undefined | undefined;
|
|
240
|
+
chainId: number;
|
|
241
|
+
type: "eip2930";
|
|
242
|
+
gasPrice: bigint;
|
|
243
|
+
maxFeePerBlobGas?: undefined | undefined;
|
|
244
|
+
maxFeePerGas?: undefined | undefined;
|
|
245
|
+
maxPriorityFeePerGas?: undefined | undefined;
|
|
246
|
+
isSystemTx?: undefined | undefined;
|
|
247
|
+
mint?: undefined | undefined;
|
|
248
|
+
sourceHash?: undefined | undefined;
|
|
249
|
+
} | {
|
|
250
|
+
blockHash: `0x${string}` | null;
|
|
251
|
+
blockNumber: bigint | null;
|
|
252
|
+
blockTimestamp?: bigint | undefined;
|
|
253
|
+
from: import("abitype").Address;
|
|
254
|
+
gas: bigint;
|
|
255
|
+
hash: import("viem").Hash;
|
|
256
|
+
input: import("viem").Hex;
|
|
257
|
+
nonce: number;
|
|
258
|
+
r: import("viem").Hex;
|
|
259
|
+
s: import("viem").Hex;
|
|
260
|
+
to: import("abitype").Address | null;
|
|
261
|
+
transactionIndex: number | null;
|
|
262
|
+
typeHex: import("viem").Hex | null;
|
|
263
|
+
v: bigint;
|
|
264
|
+
value: bigint;
|
|
265
|
+
yParity: number;
|
|
266
|
+
accessList: import("viem").AccessList;
|
|
267
|
+
authorizationList?: undefined | undefined;
|
|
268
|
+
blobVersionedHashes?: undefined | undefined;
|
|
269
|
+
chainId: number;
|
|
270
|
+
type: "eip1559";
|
|
271
|
+
gasPrice?: undefined | undefined;
|
|
272
|
+
maxFeePerBlobGas?: undefined | undefined;
|
|
273
|
+
maxFeePerGas: bigint;
|
|
274
|
+
maxPriorityFeePerGas: bigint;
|
|
275
|
+
isSystemTx?: undefined | undefined;
|
|
276
|
+
mint?: undefined | undefined;
|
|
277
|
+
sourceHash?: undefined | undefined;
|
|
278
|
+
} | {
|
|
279
|
+
blockHash: `0x${string}` | null;
|
|
280
|
+
blockNumber: bigint | null;
|
|
281
|
+
blockTimestamp?: bigint | undefined;
|
|
282
|
+
from: import("abitype").Address;
|
|
283
|
+
gas: bigint;
|
|
284
|
+
hash: import("viem").Hash;
|
|
285
|
+
input: import("viem").Hex;
|
|
286
|
+
nonce: number;
|
|
287
|
+
r: import("viem").Hex;
|
|
288
|
+
s: import("viem").Hex;
|
|
289
|
+
to: import("abitype").Address | null;
|
|
290
|
+
transactionIndex: number | null;
|
|
291
|
+
typeHex: import("viem").Hex | null;
|
|
292
|
+
v: bigint;
|
|
293
|
+
value: bigint;
|
|
294
|
+
yParity: number;
|
|
295
|
+
accessList: import("viem").AccessList;
|
|
296
|
+
authorizationList?: undefined | undefined;
|
|
297
|
+
blobVersionedHashes: readonly import("viem").Hex[];
|
|
298
|
+
chainId: number;
|
|
299
|
+
type: "eip4844";
|
|
300
|
+
gasPrice?: undefined | undefined;
|
|
301
|
+
maxFeePerBlobGas: bigint;
|
|
302
|
+
maxFeePerGas: bigint;
|
|
303
|
+
maxPriorityFeePerGas: bigint;
|
|
304
|
+
isSystemTx?: undefined | undefined;
|
|
305
|
+
mint?: undefined | undefined;
|
|
306
|
+
sourceHash?: undefined | undefined;
|
|
307
|
+
} | {
|
|
308
|
+
blockHash: `0x${string}` | null;
|
|
309
|
+
blockNumber: bigint | null;
|
|
310
|
+
blockTimestamp?: bigint | undefined;
|
|
311
|
+
from: import("abitype").Address;
|
|
312
|
+
gas: bigint;
|
|
313
|
+
hash: import("viem").Hash;
|
|
314
|
+
input: import("viem").Hex;
|
|
315
|
+
nonce: number;
|
|
316
|
+
r: import("viem").Hex;
|
|
317
|
+
s: import("viem").Hex;
|
|
318
|
+
to: import("abitype").Address | null;
|
|
319
|
+
transactionIndex: number | null;
|
|
320
|
+
typeHex: import("viem").Hex | null;
|
|
321
|
+
v: bigint;
|
|
322
|
+
value: bigint;
|
|
323
|
+
yParity: number;
|
|
324
|
+
accessList: import("viem").AccessList;
|
|
325
|
+
authorizationList: import("viem").SignedAuthorizationList;
|
|
326
|
+
blobVersionedHashes?: undefined | undefined;
|
|
327
|
+
chainId: number;
|
|
328
|
+
type: "eip7702";
|
|
329
|
+
gasPrice?: undefined | undefined;
|
|
330
|
+
maxFeePerBlobGas?: undefined | undefined;
|
|
331
|
+
maxFeePerGas: bigint;
|
|
332
|
+
maxPriorityFeePerGas: bigint;
|
|
333
|
+
isSystemTx?: undefined | undefined;
|
|
334
|
+
mint?: undefined | undefined;
|
|
335
|
+
sourceHash?: undefined | undefined;
|
|
336
|
+
}) & {};
|
|
337
|
+
type: "transaction";
|
|
338
|
+
};
|
|
339
|
+
readonly transactionReceipt: {
|
|
340
|
+
exclude: [] | undefined;
|
|
341
|
+
format: (args: import("viem/chains").OpStackRpcTransactionReceipt, action?: string | undefined) => {
|
|
342
|
+
blobGasPrice?: bigint | undefined;
|
|
343
|
+
blobGasUsed?: bigint | undefined;
|
|
344
|
+
blockHash: import("viem").Hash;
|
|
345
|
+
blockNumber: bigint;
|
|
346
|
+
blockTimestamp?: bigint | undefined;
|
|
347
|
+
contractAddress: import("abitype").Address | null | undefined;
|
|
348
|
+
cumulativeGasUsed: bigint;
|
|
349
|
+
effectiveGasPrice: bigint;
|
|
350
|
+
from: import("abitype").Address;
|
|
351
|
+
gasUsed: bigint;
|
|
352
|
+
logs: import("viem").Log<bigint, number, false>[];
|
|
353
|
+
logsBloom: import("viem").Hex;
|
|
354
|
+
root?: `0x${string}` | undefined;
|
|
355
|
+
status: "success" | "reverted";
|
|
356
|
+
to: import("abitype").Address | null;
|
|
357
|
+
transactionHash: import("viem").Hash;
|
|
358
|
+
transactionIndex: number;
|
|
359
|
+
type: import("viem").TransactionType;
|
|
360
|
+
l1GasPrice: bigint | null;
|
|
361
|
+
l1GasUsed: bigint | null;
|
|
362
|
+
l1Fee: bigint | null;
|
|
363
|
+
l1FeeScalar: number | null;
|
|
364
|
+
} & {};
|
|
365
|
+
type: "transactionReceipt";
|
|
366
|
+
};
|
|
367
|
+
};
|
|
368
|
+
prepareTransactionRequest?: ((args: import("viem").PrepareTransactionRequestParameters, options: {
|
|
369
|
+
phase: "beforeFillTransaction" | "beforeFillParameters" | "afterFillParameters";
|
|
370
|
+
}) => Promise<import("viem").PrepareTransactionRequestParameters>) | [fn: ((args: import("viem").PrepareTransactionRequestParameters, options: {
|
|
371
|
+
phase: "beforeFillTransaction" | "beforeFillParameters" | "afterFillParameters";
|
|
372
|
+
}) => Promise<import("viem").PrepareTransactionRequestParameters>) | undefined, options: {
|
|
373
|
+
runAt: readonly ("beforeFillTransaction" | "beforeFillParameters" | "afterFillParameters")[];
|
|
374
|
+
}] | undefined;
|
|
375
|
+
serializers: {
|
|
376
|
+
readonly transaction: typeof import("viem/chains").serializeTransactionOpStack;
|
|
377
|
+
};
|
|
378
|
+
verifyHash?: ((client: import("viem").Client, parameters: import("viem").VerifyHashActionParameters) => Promise<import("viem").VerifyHashActionReturnType>) | undefined;
|
|
379
|
+
readonly network: "base-sepolia";
|
|
380
|
+
};
|
|
381
|
+
export declare const ZERO_ADDRESS: Address;
|
|
382
|
+
export declare const CONTRACTS: ContractConfig;
|
|
383
|
+
export declare const WALLET_MODE: WalletMode;
|
|
384
|
+
export declare const HTTP_PORT: number;
|
|
385
|
+
/**
|
|
386
|
+
* Validates configuration on startup.
|
|
387
|
+
* Throws error if critical configuration is invalid.
|
|
388
|
+
*/
|
|
389
|
+
export declare function validateConfig(): void;
|
|
390
|
+
export declare function getPublicClient(): any;
|
|
391
|
+
export declare function getWalletClient(): any;
|
|
392
|
+
export declare function getAccount(): any;
|
|
393
|
+
export declare function loadAbi(contractName: string): any;
|
|
394
|
+
export declare function getExplorerTxUrl(hash: string): string;
|
|
395
|
+
export declare function getExplorerAddressUrl(address: string): string;
|
|
396
|
+
//# sourceMappingURL=config.d.ts.map
|
|
@@ -0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