@aarna-ai/mcp-server-atv 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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Aarna
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,123 @@
1
+ # @aarna-ai/mcp-server-atv
2
+
3
+ MCP server connector for **ATV** — AI-native access to Aarna's tokenized DeFi yield vaults on Ethereum and Base.
4
+
5
+ 19 tools for vault discovery, performance metrics (NAV, TVL, APY), deposit/withdraw/stake transaction building, and portfolio tracking.
6
+
7
+ ## Setup
8
+
9
+ Get an API key from [Aarna](https://aarna.ai), then add the config to your MCP client:
10
+
11
+ ### Claude Desktop
12
+
13
+ Edit `~/Library/Application Support/Claude/claude_desktop_config.json`:
14
+
15
+ ```json
16
+ {
17
+ "mcpServers": {
18
+ "atv": {
19
+ "url": "https://atv-api.aarna.ai/mcp",
20
+ "headers": { "x-api-key": "YOUR_API_KEY" }
21
+ }
22
+ }
23
+ }
24
+ ```
25
+
26
+ ### Claude Code
27
+
28
+ ```bash
29
+ claude mcp add atv --transport http https://atv-api.aarna.ai/mcp --header "x-api-key: YOUR_API_KEY"
30
+ ```
31
+
32
+ ### Cursor
33
+
34
+ Create `.cursor/mcp.json` in your project root:
35
+
36
+ ```json
37
+ {
38
+ "mcpServers": {
39
+ "atv": {
40
+ "url": "https://atv-api.aarna.ai/mcp",
41
+ "headers": { "x-api-key": "YOUR_API_KEY" }
42
+ }
43
+ }
44
+ }
45
+ ```
46
+
47
+ ### VS Code (Copilot)
48
+
49
+ Add to `.vscode/settings.json`:
50
+
51
+ ```json
52
+ {
53
+ "mcp": {
54
+ "servers": {
55
+ "atv": {
56
+ "url": "https://atv-api.aarna.ai/mcp",
57
+ "headers": { "x-api-key": "YOUR_API_KEY" }
58
+ }
59
+ }
60
+ }
61
+ }
62
+ ```
63
+
64
+ ### mcp-remote (stdio-only clients)
65
+
66
+ ```json
67
+ {
68
+ "mcpServers": {
69
+ "atv": {
70
+ "command": "npx",
71
+ "args": ["-y", "mcp-remote", "https://atv-api.aarna.ai/mcp", "--header", "x-api-key:YOUR_API_KEY"]
72
+ }
73
+ }
74
+ }
75
+ ```
76
+
77
+ ## Tools (19)
78
+
79
+ | Tool | Description |
80
+ |------|-------------|
81
+ | `list_vaults` | List all vaults, optionally filter by chain |
82
+ | `get_vault` | Vault metadata by address |
83
+ | `get_vault_nav` | Current NAV in USD |
84
+ | `get_vault_tvl` | Current TVL in USD |
85
+ | `get_vault_apy` | APY breakdown (base + reward + total) |
86
+ | `get_deposit_status` | Whether deposits are paused |
87
+ | `get_withdraw_status` | Whether withdrawals are paused |
88
+ | `get_queue_withdraw_status` | Whether queued withdrawals are paused |
89
+ | `build_deposit_tx` | Build approve + deposit steps |
90
+ | `build_withdraw_tx` | Build withdrawal steps |
91
+ | `build_stake_tx` | Build approve + stake steps |
92
+ | `build_unstake_tx` | Build unstake step |
93
+ | `build_queue_withdraw_tx` | Initiate queued withdrawal |
94
+ | `build_unqueue_withdraw_tx` | Cancel pending queued withdrawal |
95
+ | `build_redeem_withdraw_tx` | Claim completed queued withdrawal |
96
+ | `get_vault_balance` | Underlying token breakdown |
97
+ | `get_historical_nav` | NAV over N days |
98
+ | `get_total_tvl` | Platform-wide or per-vault TVL |
99
+ | `get_user_investments` | User portfolio and positions |
100
+
101
+ ## Example Prompts
102
+
103
+ - "What DeFi vaults are available on Base?"
104
+ - "What's the current APY for vault 0x...?"
105
+ - "Build a deposit of 1000 USDC into vault 0x..."
106
+ - "Show my portfolio across all Aarna vaults"
107
+ - "Is the queue-withdraw paused on vault 0x...?"
108
+
109
+ ## Programmatic Usage
110
+
111
+ ```ts
112
+ import { mcpConfig, TOOLS, MCP_SERVER_URL } from '@aarna-ai/mcp-server-atv';
113
+
114
+ // Generate config for any MCP client
115
+ const config = mcpConfig('your-api-key');
116
+
117
+ console.log(MCP_SERVER_URL); // https://atv-api.aarna.ai/mcp
118
+ console.log(TOOLS.length); // 19
119
+ ```
120
+
121
+ ## License
122
+
123
+ MIT
@@ -0,0 +1,27 @@
1
+ /** Default MCP server URL for the hosted ATV server. */
2
+ declare const MCP_SERVER_URL = "https://atv-api.aarna.ai/mcp";
3
+ /** MCP server name as registered in the protocol. */
4
+ declare const MCP_SERVER_NAME = "atv";
5
+ /** MCP server version. */
6
+ declare const MCP_SERVER_VERSION = "1.0.0";
7
+ /** All 19 tools exposed by the ATV MCP server. */
8
+ declare const TOOLS: readonly ["list_vaults", "get_vault", "get_vault_nav", "get_vault_tvl", "get_vault_apy", "get_deposit_status", "get_withdraw_status", "get_queue_withdraw_status", "build_deposit_tx", "build_withdraw_tx", "build_stake_tx", "build_unstake_tx", "build_queue_withdraw_tx", "build_unqueue_withdraw_tx", "build_redeem_withdraw_tx", "get_vault_balance", "get_historical_nav", "get_total_tvl", "get_user_investments"];
9
+ type AtvTool = (typeof TOOLS)[number];
10
+ /**
11
+ * Generate an MCP client config object for connecting to the ATV server.
12
+ *
13
+ * Drop the result into `claude_desktop_config.json`, `.cursor/mcp.json`,
14
+ * or `.vscode/settings.json` under `mcp.servers`.
15
+ */
16
+ declare function mcpConfig(apiKey: string, url?: string): {
17
+ mcpServers: {
18
+ atv: {
19
+ url: string;
20
+ headers: {
21
+ "x-api-key": string;
22
+ };
23
+ };
24
+ };
25
+ };
26
+
27
+ export { type AtvTool, MCP_SERVER_NAME, MCP_SERVER_URL, MCP_SERVER_VERSION, TOOLS, mcpConfig };
@@ -0,0 +1,27 @@
1
+ /** Default MCP server URL for the hosted ATV server. */
2
+ declare const MCP_SERVER_URL = "https://atv-api.aarna.ai/mcp";
3
+ /** MCP server name as registered in the protocol. */
4
+ declare const MCP_SERVER_NAME = "atv";
5
+ /** MCP server version. */
6
+ declare const MCP_SERVER_VERSION = "1.0.0";
7
+ /** All 19 tools exposed by the ATV MCP server. */
8
+ declare const TOOLS: readonly ["list_vaults", "get_vault", "get_vault_nav", "get_vault_tvl", "get_vault_apy", "get_deposit_status", "get_withdraw_status", "get_queue_withdraw_status", "build_deposit_tx", "build_withdraw_tx", "build_stake_tx", "build_unstake_tx", "build_queue_withdraw_tx", "build_unqueue_withdraw_tx", "build_redeem_withdraw_tx", "get_vault_balance", "get_historical_nav", "get_total_tvl", "get_user_investments"];
9
+ type AtvTool = (typeof TOOLS)[number];
10
+ /**
11
+ * Generate an MCP client config object for connecting to the ATV server.
12
+ *
13
+ * Drop the result into `claude_desktop_config.json`, `.cursor/mcp.json`,
14
+ * or `.vscode/settings.json` under `mcp.servers`.
15
+ */
16
+ declare function mcpConfig(apiKey: string, url?: string): {
17
+ mcpServers: {
18
+ atv: {
19
+ url: string;
20
+ headers: {
21
+ "x-api-key": string;
22
+ };
23
+ };
24
+ };
25
+ };
26
+
27
+ export { type AtvTool, MCP_SERVER_NAME, MCP_SERVER_URL, MCP_SERVER_VERSION, TOOLS, mcpConfig };
package/dist/index.js ADDED
@@ -0,0 +1,79 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // src/index.ts
21
+ var index_exports = {};
22
+ __export(index_exports, {
23
+ MCP_SERVER_NAME: () => MCP_SERVER_NAME,
24
+ MCP_SERVER_URL: () => MCP_SERVER_URL,
25
+ MCP_SERVER_VERSION: () => MCP_SERVER_VERSION,
26
+ TOOLS: () => TOOLS,
27
+ mcpConfig: () => mcpConfig
28
+ });
29
+ module.exports = __toCommonJS(index_exports);
30
+
31
+ // src/config.ts
32
+ var MCP_SERVER_URL = "https://atv-api.aarna.ai/mcp";
33
+ var MCP_SERVER_NAME = "atv";
34
+ var MCP_SERVER_VERSION = "1.0.0";
35
+ var TOOLS = [
36
+ // Discovery & metadata
37
+ "list_vaults",
38
+ "get_vault",
39
+ // Performance metrics
40
+ "get_vault_nav",
41
+ "get_vault_tvl",
42
+ "get_vault_apy",
43
+ // Operational status
44
+ "get_deposit_status",
45
+ "get_withdraw_status",
46
+ "get_queue_withdraw_status",
47
+ // Transaction builders (instant)
48
+ "build_deposit_tx",
49
+ "build_withdraw_tx",
50
+ "build_stake_tx",
51
+ "build_unstake_tx",
52
+ // Transaction builders (queued)
53
+ "build_queue_withdraw_tx",
54
+ "build_unqueue_withdraw_tx",
55
+ "build_redeem_withdraw_tx",
56
+ // Analytics
57
+ "get_vault_balance",
58
+ "get_historical_nav",
59
+ "get_total_tvl",
60
+ "get_user_investments"
61
+ ];
62
+ function mcpConfig(apiKey, url = MCP_SERVER_URL) {
63
+ return {
64
+ mcpServers: {
65
+ atv: {
66
+ url,
67
+ headers: { "x-api-key": apiKey }
68
+ }
69
+ }
70
+ };
71
+ }
72
+ // Annotate the CommonJS export names for ESM import in node:
73
+ 0 && (module.exports = {
74
+ MCP_SERVER_NAME,
75
+ MCP_SERVER_URL,
76
+ MCP_SERVER_VERSION,
77
+ TOOLS,
78
+ mcpConfig
79
+ });
package/dist/index.mjs ADDED
@@ -0,0 +1,48 @@
1
+ // src/config.ts
2
+ var MCP_SERVER_URL = "https://atv-api.aarna.ai/mcp";
3
+ var MCP_SERVER_NAME = "atv";
4
+ var MCP_SERVER_VERSION = "1.0.0";
5
+ var TOOLS = [
6
+ // Discovery & metadata
7
+ "list_vaults",
8
+ "get_vault",
9
+ // Performance metrics
10
+ "get_vault_nav",
11
+ "get_vault_tvl",
12
+ "get_vault_apy",
13
+ // Operational status
14
+ "get_deposit_status",
15
+ "get_withdraw_status",
16
+ "get_queue_withdraw_status",
17
+ // Transaction builders (instant)
18
+ "build_deposit_tx",
19
+ "build_withdraw_tx",
20
+ "build_stake_tx",
21
+ "build_unstake_tx",
22
+ // Transaction builders (queued)
23
+ "build_queue_withdraw_tx",
24
+ "build_unqueue_withdraw_tx",
25
+ "build_redeem_withdraw_tx",
26
+ // Analytics
27
+ "get_vault_balance",
28
+ "get_historical_nav",
29
+ "get_total_tvl",
30
+ "get_user_investments"
31
+ ];
32
+ function mcpConfig(apiKey, url = MCP_SERVER_URL) {
33
+ return {
34
+ mcpServers: {
35
+ atv: {
36
+ url,
37
+ headers: { "x-api-key": apiKey }
38
+ }
39
+ }
40
+ };
41
+ }
42
+ export {
43
+ MCP_SERVER_NAME,
44
+ MCP_SERVER_URL,
45
+ MCP_SERVER_VERSION,
46
+ TOOLS,
47
+ mcpConfig
48
+ };
package/package.json ADDED
@@ -0,0 +1,49 @@
1
+ {
2
+ "name": "@aarna-ai/mcp-server-atv",
3
+ "version": "1.0.0",
4
+ "description": "MCP server connector for ATV — AI-native access to Aarna's DeFi yield vaults on Ethereum and Base",
5
+ "keywords": [
6
+ "mcp",
7
+ "mcp-server",
8
+ "defi",
9
+ "yield",
10
+ "usdc",
11
+ "pendle",
12
+ "erc-4626",
13
+ "vault",
14
+ "agentic",
15
+ "fixed-income",
16
+ "stablecoin",
17
+ "aarna",
18
+ "atv",
19
+ "atv"
20
+ ],
21
+ "homepage": "https://github.com/aarna-ai/atv-sdk",
22
+ "repository": {
23
+ "type": "git",
24
+ "url": "https://github.com/aarna-ai/atv-sdk.git",
25
+ "directory": "packages/mcp-server"
26
+ },
27
+ "license": "MIT",
28
+ "main": "./dist/index.js",
29
+ "module": "./dist/index.mjs",
30
+ "types": "./dist/index.d.ts",
31
+ "exports": {
32
+ ".": {
33
+ "types": "./dist/index.d.ts",
34
+ "require": "./dist/index.js",
35
+ "import": "./dist/index.mjs"
36
+ }
37
+ },
38
+ "files": [
39
+ "dist",
40
+ "README.md"
41
+ ],
42
+ "devDependencies": {
43
+ "tsup": "^8.0.0",
44
+ "typescript": "^5.3.0"
45
+ },
46
+ "scripts": {
47
+ "build": "tsup src/index.ts --format cjs,esm --dts --clean"
48
+ }
49
+ }