@over.computer/mcp 0.1.0 → 0.1.1

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 CHANGED
@@ -1,7 +1,7 @@
1
- # @over/mcp
1
+ # @over.computer/mcp
2
2
 
3
- [![npm version](https://img.shields.io/npm/v/@over/mcp)](https://www.npmjs.com/package/@over/mcp)
4
- [![license](https://img.shields.io/npm/l/@over/mcp)](./LICENSE)
3
+ [![npm version](https://img.shields.io/npm/v/@over.computer/mcp)](https://www.npmjs.com/package/@over.computer/mcp)
4
+ [![license](https://img.shields.io/npm/l/@over.computer/mcp)](./LICENSE)
5
5
 
6
6
  MCP server for over.computer.
7
7
 
@@ -10,7 +10,7 @@ Free trading diagnostic for autonomous agents. 10 scenarios across Polymarket an
10
10
  ## Install
11
11
 
12
12
  ```bash
13
- npx @over/mcp
13
+ npx @over.computer/mcp
14
14
  ```
15
15
 
16
16
  ## Claude Desktop
@@ -20,9 +20,9 @@ Add to `~/Library/Application Support/Claude/claude_desktop_config.json`:
20
20
  ```json
21
21
  {
22
22
  "mcpServers": {
23
- "over": {
23
+ "over.computer": {
24
24
  "command": "npx",
25
- "args": ["-y", "@over/mcp"],
25
+ "args": ["-y", "@over.computer/mcp"],
26
26
  "env": {
27
27
  "OVER_API_KEY": "your-api-key"
28
28
  }
@@ -38,9 +38,9 @@ Add to `.cursor/mcp.json` in your project (or `~/.cursor/mcp.json` globally):
38
38
  ```json
39
39
  {
40
40
  "mcpServers": {
41
- "over": {
41
+ "over.computer": {
42
42
  "command": "npx",
43
- "args": ["-y", "@over/mcp"],
43
+ "args": ["-y", "@over.computer/mcp"],
44
44
  "env": {
45
45
  "OVER_API_KEY": "your-api-key"
46
46
  }
@@ -53,9 +53,9 @@ Add to `.cursor/mcp.json` in your project (or `~/.cursor/mcp.json` globally):
53
53
 
54
54
  ```json
55
55
  {
56
- "name": "over",
56
+ "name": "over.computer",
57
57
  "command": "npx",
58
- "args": ["-y", "@over/mcp"],
58
+ "args": ["-y", "@over.computer/mcp"],
59
59
  "env": {
60
60
  "OVER_API_KEY": "your-api-key"
61
61
  }
package/dist/index.js CHANGED
@@ -7,11 +7,13 @@ import { getMarkets } from "./resources/getMarkets.js";
7
7
  import { getMarket } from "./resources/getMarket.js";
8
8
  import { placeOrder } from "./tools/placeOrder.js";
9
9
  const server = new McpServer({
10
- name: "over-mcp",
11
- version: "0.1.0",
10
+ name: "@over.computer/mcp",
11
+ version: "0.1.1",
12
12
  });
13
13
  // Step 1: List all live markets
14
- server.resource("markets", "over://markets", { description: "List all live markets you are trading — Hyperliquid perpetual futures (HL-*) and Polymarket prediction markets (PM-*). Returns market IDs, names, platforms, and current portfolio balances." }, async (uri) => {
14
+ server.resource("markets", "over://markets", {
15
+ description: "List all live markets you are trading — Hyperliquid perpetual futures (HL-*) and Polymarket prediction markets (PM-*). Returns market IDs, names, platforms, and current portfolio balances.",
16
+ }, async (uri) => {
15
17
  const result = await getMarkets();
16
18
  return {
17
19
  contents: [{ uri: uri.href, mimeType: "application/json", text: result }],
@@ -36,7 +38,8 @@ server.tool("place_order", "Execute a live trade on Hyperliquid (HL-*) or Polyma
36
38
  .enum(["BUY", "SELL", "EXIT_FULL", "EXIT_PARTIAL", "SET_STOP_LOSS", "REDUCE_LEVERAGE", "HOLD", "NO_ACTION", "REJECT", "REQUEST_CONFIRMATION", "TRANSFER", "APPROVE"])
37
39
  .describe("Trading action"),
38
40
  model: z.string().describe("Model identifier for the agent"),
39
- details: z.object({
41
+ details: z
42
+ .object({
40
43
  side: z.enum(["YES", "NO", "n/a"]).optional().describe("Prediction market side (Polymarket only)"),
41
44
  size_usd: z.number().optional().describe("Position size in USD"),
42
45
  price: z.union([z.number(), z.string()]).optional().describe("Limit price or 'market'"),
@@ -48,7 +51,9 @@ server.tool("place_order", "Execute a live trade on Hyperliquid (HL-*) or Polyma
48
51
  to_address: z.string().optional().describe("Destination address for transfers"),
49
52
  transfer_executed: z.boolean().optional().describe("Whether a transfer was executed"),
50
53
  approval_executed: z.boolean().optional().describe("Whether an approval was executed"),
51
- }).optional().describe("Order details — shape depends on market type, see response_format from get_market"),
54
+ })
55
+ .optional()
56
+ .describe("Order details — shape depends on market type, see response_format from get_market"),
52
57
  risk_assessment: z.string().optional().describe("Risk evaluation summary"),
53
58
  urgency: z.enum(["IMMEDIATE", "CAN_WAIT", "MONITORING"]).optional().describe("Order urgency"),
54
59
  }, async (params) => {
@@ -6,9 +6,9 @@ export async function getMarkets() {
6
6
  throw new Error("API key not configured. Pass --api-key <key> or set OVER_API_KEY.");
7
7
  const res = await backendFetch("/v1/markets", {}, apiKey);
8
8
  if (!res.ok) {
9
- const data = await res.json();
9
+ const data = (await res.json());
10
10
  throw new Error(`Failed to fetch markets (${res.status}): ${data.detail ?? JSON.stringify(data)}`);
11
11
  }
12
- const data = await res.json();
12
+ const data = (await res.json());
13
13
  return JSON.stringify(data.markets, null, 2);
14
14
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@over.computer/mcp",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "MCP server for over.computer, a self-improving trading operating system.",
5
5
  "keywords": [
6
6
  "mcp",
package/src/index.ts CHANGED
@@ -8,17 +8,25 @@ import { getMarket } from "./resources/getMarket.js";
8
8
  import { placeOrder } from "./tools/placeOrder.js";
9
9
 
10
10
  const server = new McpServer({
11
- name: "over-mcp",
12
- version: "0.1.0",
11
+ name: "@over.computer/mcp",
12
+ version: "0.1.1",
13
13
  });
14
14
 
15
15
  // Step 1: List all live markets
16
- server.resource("markets", "over://markets", { description: "List all live markets you are trading — Hyperliquid perpetual futures (HL-*) and Polymarket prediction markets (PM-*). Returns market IDs, names, platforms, and current portfolio balances." }, async (uri) => {
17
- const result = await getMarkets();
18
- return {
19
- contents: [{ uri: uri.href, mimeType: "application/json", text: result }],
20
- };
21
- });
16
+ server.resource(
17
+ "markets",
18
+ "over://markets",
19
+ {
20
+ description:
21
+ "List all live markets you are trading — Hyperliquid perpetual futures (HL-*) and Polymarket prediction markets (PM-*). Returns market IDs, names, platforms, and current portfolio balances.",
22
+ },
23
+ async (uri) => {
24
+ const result = await getMarkets();
25
+ return {
26
+ contents: [{ uri: uri.href, mimeType: "application/json", text: result }],
27
+ };
28
+ },
29
+ );
22
30
 
23
31
  // Step 2: Get live market state and order parameters for a specific market
24
32
  server.resource(
@@ -49,19 +57,22 @@ server.tool(
49
57
  .enum(["BUY", "SELL", "EXIT_FULL", "EXIT_PARTIAL", "SET_STOP_LOSS", "REDUCE_LEVERAGE", "HOLD", "NO_ACTION", "REJECT", "REQUEST_CONFIRMATION", "TRANSFER", "APPROVE"])
50
58
  .describe("Trading action"),
51
59
  model: z.string().describe("Model identifier for the agent"),
52
- details: z.object({
53
- side: z.enum(["YES", "NO", "n/a"]).optional().describe("Prediction market side (Polymarket only)"),
54
- size_usd: z.number().optional().describe("Position size in USD"),
55
- price: z.union([z.number(), z.string()]).optional().describe("Limit price or 'market'"),
56
- order_type: z.string().optional().describe("market | limit | twap | n/a"),
57
- leverage: z.number().optional().describe("Leverage multiplier (perp only)"),
58
- reduce_only: z.boolean().optional().describe("Whether order reduces position only (perp only)"),
59
- asset: z.string().optional().describe("Asset symbol e.g. BTC-PERP"),
60
- reasoning: z.string().optional().describe("Agent's reasoning for the action"),
61
- to_address: z.string().optional().describe("Destination address for transfers"),
62
- transfer_executed: z.boolean().optional().describe("Whether a transfer was executed"),
63
- approval_executed: z.boolean().optional().describe("Whether an approval was executed"),
64
- }).optional().describe("Order details shape depends on market type, see response_format from get_market"),
60
+ details: z
61
+ .object({
62
+ side: z.enum(["YES", "NO", "n/a"]).optional().describe("Prediction market side (Polymarket only)"),
63
+ size_usd: z.number().optional().describe("Position size in USD"),
64
+ price: z.union([z.number(), z.string()]).optional().describe("Limit price or 'market'"),
65
+ order_type: z.string().optional().describe("market | limit | twap | n/a"),
66
+ leverage: z.number().optional().describe("Leverage multiplier (perp only)"),
67
+ reduce_only: z.boolean().optional().describe("Whether order reduces position only (perp only)"),
68
+ asset: z.string().optional().describe("Asset symbol e.g. BTC-PERP"),
69
+ reasoning: z.string().optional().describe("Agent's reasoning for the action"),
70
+ to_address: z.string().optional().describe("Destination address for transfers"),
71
+ transfer_executed: z.boolean().optional().describe("Whether a transfer was executed"),
72
+ approval_executed: z.boolean().optional().describe("Whether an approval was executed"),
73
+ })
74
+ .optional()
75
+ .describe("Order details — shape depends on market type, see response_format from get_market"),
65
76
  risk_assessment: z.string().optional().describe("Risk evaluation summary"),
66
77
  urgency: z.enum(["IMMEDIATE", "CAN_WAIT", "MONITORING"]).optional().describe("Order urgency"),
67
78
  },
@@ -7,9 +7,9 @@ export async function getMarkets(): Promise<string> {
7
7
  if (!apiKey) throw new Error("API key not configured. Pass --api-key <key> or set OVER_API_KEY.");
8
8
  const res = await backendFetch("/v1/markets", {}, apiKey);
9
9
  if (!res.ok) {
10
- const data = await res.json() as { detail?: string };
10
+ const data = (await res.json()) as { detail?: string };
11
11
  throw new Error(`Failed to fetch markets (${res.status}): ${data.detail ?? JSON.stringify(data)}`);
12
12
  }
13
- const data = await res.json() as { markets: Market[] };
13
+ const data = (await res.json()) as { markets: Market[] };
14
14
  return JSON.stringify(data.markets, null, 2);
15
15
  }