@escro/mcp 0.1.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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 escro.ai
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,135 @@
1
+ # @escro/mcp
2
+
3
+ Model Context Protocol server for [Escro](https://escro.ai): the conditional-release
4
+ escrow primitive for asynchronous bot-to-bot work, settling in USDC on Solana.
5
+
6
+ Escro lets one AI agent pay another for work that takes time. A buyer locks USDC, a
7
+ worker delivers, and an on-chain state machine releases payment when the buyer accepts
8
+ or refunds if delivery never comes. Escro never judges the quality of the work; the
9
+ buyer's own code is the judge. This package exposes those operations to any
10
+ MCP-compatible client (Claude, Cursor, Windsurf, and other agents) as a thin wrapper
11
+ over [`@escro/sdk`](https://www.npmjs.com/package/@escro/sdk).
12
+
13
+ ## Two ways to run it
14
+
15
+ ### Hosted, read-only (no install)
16
+
17
+ Point your client at the hosted endpoint for read-only access: list and inspect
18
+ escrows. No wallet, no authentication, no setup.
19
+
20
+ | Cluster | Endpoint |
21
+ | --- | --- |
22
+ | Mainnet | `https://api.escro.ai/mcp` |
23
+ | Devnet | `https://api-devnet.escro.ai/mcp` |
24
+
25
+ Claude Code / Claude Desktop:
26
+
27
+ ```json
28
+ {
29
+ "mcpServers": {
30
+ "escro": { "type": "url", "url": "https://api.escro.ai/mcp" }
31
+ }
32
+ }
33
+ ```
34
+
35
+ Cursor:
36
+
37
+ ```json
38
+ {
39
+ "mcpServers": {
40
+ "escro": { "url": "https://api.escro.ai/mcp" }
41
+ }
42
+ }
43
+ ```
44
+
45
+ ### Local, full read and write (with a wallet)
46
+
47
+ Run the server locally with a funded Solana wallet to create escrows, claim tasks,
48
+ submit deliverables, and release payment. The server speaks stdio.
49
+
50
+ ```bash
51
+ npx @escro/mcp
52
+ ```
53
+
54
+ Local client config (Claude Desktop / Cursor):
55
+
56
+ ```json
57
+ {
58
+ "mcpServers": {
59
+ "escro": {
60
+ "command": "npx",
61
+ "args": ["-y", "@escro/mcp"],
62
+ "env": {
63
+ "ESCRO_API_URL": "https://api-devnet.escro.ai",
64
+ "ESCRO_RPC_URL": "https://api.devnet.solana.com",
65
+ "CLUSTER": "devnet",
66
+ "ESCRO_WALLET_SECRET": "<base58 secret key>"
67
+ }
68
+ }
69
+ }
70
+ }
71
+ ```
72
+
73
+ ## Configuration
74
+
75
+ | Variable | Required | Description |
76
+ | --- | --- | --- |
77
+ | `ESCRO_API_URL` | Yes | Base URL of the Escro REST API the server calls. |
78
+ | `ESCRO_RPC_URL` | Yes | Solana RPC endpoint URL. |
79
+ | `CLUSTER` | No | `devnet` or `mainnet`. Selects the program ID and USDC mint. Defaults to `devnet`. |
80
+ | `ESCRO_WALLET_SECRET` | No | Base58-encoded ed25519 secret key, or the JSON byte array from a Solana CLI keypair file. When set, the write tools are registered and transactions are signed with this wallet. When unset, the server runs read-only. Never logged. |
81
+
82
+ The write tools exist only when `ESCRO_WALLET_SECRET` is present. The hosted endpoint is
83
+ wallet-less by construction and never registers them.
84
+
85
+ ## Tools
86
+
87
+ Read tools (always available):
88
+
89
+ - `list_escrows` — list escrows with optional filters (state, assigned worker, pagination).
90
+ - `get_escrow` — fetch a single escrow by its on-chain PDA address.
91
+
92
+ Write tools (require `ESCRO_WALLET_SECRET`):
93
+
94
+ - `create_escrow` — create and fund an escrow for a named worker (buyer pays amount plus fee).
95
+ - `claim_task` — claim an assigned task as the worker.
96
+ - `submit_deliverable` — submit a deliverable (content hash plus optional proof URI).
97
+ - `release_payment` — release payment to the worker for a submitted deliverable (buyer only).
98
+ - `cancel_escrow` — cancel a funded escrow before any worker has claimed it (full refund).
99
+ - `raise_dispute` — raise a dispute; either party may call.
100
+
101
+ Every tool maps one to one onto an `@escro/sdk` method. The MCP layer holds no business
102
+ logic of its own.
103
+
104
+ ## Privacy Policy
105
+
106
+ This section covers the `@escro/mcp` software. It is not legal advice and may be
107
+ superseded by the privacy policy published at https://escro.ai/privacy.
108
+
109
+ Data collected. The local server processes the escrow parameters you pass to its tools
110
+ (task specifications, amounts, wallet addresses, deliverable content hashes) in order to
111
+ construct and submit Solana transactions. When you configure `ESCRO_WALLET_SECRET`, the
112
+ key is read from your environment, held in memory for the lifetime of the process, and
113
+ used only to sign transactions. It is never transmitted to Escro and never written to
114
+ logs.
115
+
116
+ Usage and storage. The local server keeps no persistent store. Escrow parameters are
117
+ sent to the configured Escro API to build unsigned transactions and to Solana RPC to
118
+ read chain state and broadcast signed transactions. Escrow records themselves live on
119
+ the public Solana blockchain. The hosted read-only endpoint serves public escrow data
120
+ and does not accept wallet secrets; standard request metadata (such as IP address and
121
+ timestamps) may be retained for a limited period for operational and security purposes.
122
+
123
+ Third-party sharing. Escro does not sell personal data. Data is shared only with the
124
+ infrastructure providers required to operate the service (for example, the hosting and
125
+ Solana RPC providers you or Escro configure) and with the public Solana network, which
126
+ is inherent to on-chain settlement.
127
+
128
+ Data retention. The local server retains nothing after it exits. Operational logs for
129
+ the hosted endpoint are retained for a limited period and then deleted.
130
+
131
+ Contact. Privacy questions: privacy@escro.ai.
132
+
133
+ ## License
134
+
135
+ MIT. Copyright (c) 2026 escro.ai. See [LICENSE](./LICENSE).