{"_id":"@astroblock/mcp","name":"@astroblock/mcp","dist-tags":{"latest":"0.1.0"},"versions":{"0.1.0":{"name":"@astroblock/mcp","version":"0.1.0","description":"MCP Server for AI agents to play Astroblock — explore, move ships, discover stars, claim loot","type":"module","main":"dist/index.js","bin":{"astroblock-mcp":"dist/bin/cli.js"},"dependencies":{"@modelcontextprotocol/sdk":"^0.6.0","viem":"2.45.0","commander":"^12.0.0","zod":"^3.23.0"},"devDependencies":{"@types/node":"^20.0.0","tsup":"^8.0.0","typescript":"^5.4.0"},"keywords":["astroblock","mcp","ai-agents","onchain","base"],"scripts":{"build":"tsup","serve":"node dist/index.js","typecheck":"tsc --noEmit"},"_id":"@astroblock/mcp@0.1.0","_integrity":"sha512-SWQn+V18otLGGRwP+T3uZfZB1kwJlEHHGVd1je9KkSOlf4nsekBQqtTdXTBRQz1tf08l4daurCf2aDBz0PuUHw==","_resolved":"/tmp/dd5ddebbeeaac13d8d22a04e32a59a10/astroblock-mcp-0.1.0.tgz","_from":"file:astroblock-mcp-0.1.0.tgz","_nodeVersion":"20.20.0","_npmVersion":"10.8.2","dist":{"integrity":"sha512-SWQn+V18otLGGRwP+T3uZfZB1kwJlEHHGVd1je9KkSOlf4nsekBQqtTdXTBRQz1tf08l4daurCf2aDBz0PuUHw==","shasum":"728ba0f0d5e113a65d19a48a41432b353376a2d3","tarball":"https://registry.npmjs.org/@astroblock/mcp/-/mcp-0.1.0.tgz","fileCount":3,"unpackedSize":4328,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCEcdkRXpIbtGWLF7RcamAtsxvUcdMD8+o88BN3CCZazAIgI9kw+6sh4adjY3sGjwk05AtDO9w1CIejaxMi03YwCGc="}]},"_npmUser":{"name":"nezz0746","email":"nezz0746@gmail.com"},"directories":{},"maintainers":[{"name":"nezz0746","email":"nezz0746@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/mcp_0.1.0_1770915469820_0.5961772099279958"},"_hasShrinkwrap":false}},"time":{"created":"2026-02-12T16:57:49.684Z","0.1.0":"2026-02-12T16:57:50.028Z","modified":"2026-02-12T16:57:50.324Z"},"maintainers":[{"name":"nezz0746","email":"nezz0746@gmail.com"}],"description":"MCP Server for AI agents to play Astroblock — explore, move ships, discover stars, claim loot","keywords":["astroblock","mcp","ai-agents","onchain","base"],"readme":"# @astroblock/agent-mcp\n\nMCP (Model Context Protocol) server for AI agents to interact with Astroblock.\n\n## Installation\n\n```bash\npnpm add @astroblock/agent-mcp\n```\n\n## Usage\n\n### As MCP Server\n\nStart the MCP server for use with Claude, OpenAI, or other MCP-compatible clients:\n\n```bash\n# Set environment variables\nexport ASTRO_CHAIN=base-sepolia\nexport ASTRO_PRIVATE_KEY=0x...  # Optional, for write operations\n\n# Start server\nnpx astroblock-mcp serve\n```\n\n### Claude Desktop Configuration\n\nAdd to your Claude Desktop config (`~/Library/Application Support/Claude/claude_desktop_config.json`):\n\n```json\n{\n  \"mcpServers\": {\n    \"astroblock\": {\n      \"command\": \"npx\",\n      \"args\": [\"astroblock-mcp\", \"serve\"],\n      \"env\": {\n        \"ASTRO_CHAIN\": \"base-sepolia\",\n        \"ASTRO_PRIVATE_KEY\": \"0x...\"\n      }\n    }\n  }\n}\n```\n\n### CLI Usage\n\n```bash\n# Get entity info\nastroblock-mcp get-entity --id 123\n\n# Get entities in area\nastroblock-mcp get-entities --x 100 --y 200 --radius 50\n\n# Get fuel balance\nastroblock-mcp get-fuel --id 123\n\n# Get map snapshot\nastroblock-mcp get-map --x 100 --y 200 --radius 100\n\n# Move entity (requires private key)\nastroblock-mcp move --id 123 --x 150 --y 250 --private-key 0x...\n\n# Discover star (requires private key)\nastroblock-mcp discover-star --entity 123 --star 456 --private-key 0x...\n```\n\n### Global Options\n\n| Option | Description | Default |\n|--------|-------------|---------|\n| `-c, --chain` | Chain to use | `base-sepolia` |\n| `-r, --rpc` | Custom RPC URL | Chain default |\n| `-k, --private-key` | Private key for writes | None |\n\n## Available Tools\n\n### Read Operations\n\n| Tool | Description |\n|------|-------------|\n| `get_entity` | Get entity by ID (position, owner, type) |\n| `get_entities_in_area` | Get all entities within radius |\n| `get_star_info` | Get star metadata |\n| `get_fuel_balance` | Get fuel balance for entity |\n| `get_map_state` | Snapshot of map around coordinates |\n\n### Write Operations\n\n| Tool | Description |\n|------|-------------|\n| `move` | Move entity to new coordinates |\n| `discover_star` | Claim star discovery |\n\n## Environment Variables\n\n| Variable | Description |\n|----------|-------------|\n| `ASTRO_CHAIN` | Chain: `base`, `base-sepolia`, `celo`, `celo-sepolia` |\n| `ASTRO_RPC_URL` | Custom RPC URL |\n| `ASTRO_PRIVATE_KEY` | Wallet private key |\n| `ASTRO_MAP_ADDRESS` | Override map contract address |\n\n## Development\n\n```bash\n# Build\npnpm build\n\n# Watch mode\npnpm dev\n\n# Type check\npnpm typecheck\n```\n\n## License\n\nMIT\n","readmeFilename":"README.md","_rev":"1-55ec51ee59256cfdafcac6b24764345b"}