@openephemeris/mcp-server 3.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 +163 -0
- package/config/dev-allowlist.json +1165 -0
- package/dist/backend/client.d.ts +33 -0
- package/dist/backend/client.js +167 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +87 -0
- package/dist/schema-packs/llm.d.ts +105 -0
- package/dist/schema-packs/llm.js +429 -0
- package/dist/tools/dev.d.ts +1 -0
- package/dist/tools/dev.js +183 -0
- package/dist/tools/index.d.ts +18 -0
- package/dist/tools/index.js +31 -0
- package/dist/tools/specialized/eclipse.d.ts +1 -0
- package/dist/tools/specialized/eclipse.js +56 -0
- package/dist/tools/specialized/electional.d.ts +1 -0
- package/dist/tools/specialized/electional.js +79 -0
- package/dist/tools/specialized/human_design.d.ts +1 -0
- package/dist/tools/specialized/human_design.js +53 -0
- package/dist/tools/specialized/moon.d.ts +1 -0
- package/dist/tools/specialized/moon.js +50 -0
- package/dist/tools/specialized/natal.d.ts +1 -0
- package/dist/tools/specialized/natal.js +71 -0
- package/dist/tools/specialized/relocation.d.ts +1 -0
- package/dist/tools/specialized/relocation.js +71 -0
- package/dist/tools/specialized/synastry.d.ts +1 -0
- package/dist/tools/specialized/synastry.js +61 -0
- package/dist/tools/specialized/transits.d.ts +1 -0
- package/dist/tools/specialized/transits.js +80 -0
- package/package.json +60 -0
package/README.md
ADDED
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
# OpenEphemeris MCP Server
|
|
2
|
+
|
|
3
|
+
Model Context Protocol server for OpenEphemeris. This package exposes typed astrology tools and an allowlist-gated generic proxy (`dev.call`) for MCP-compatible clients.
|
|
4
|
+
|
|
5
|
+
## Quick Start
|
|
6
|
+
|
|
7
|
+
### One-click install (Cursor)
|
|
8
|
+
|
|
9
|
+
<!-- GENERATED:CURSOR_INSTALL:BEGIN -->
|
|
10
|
+
[](cursor://anysphere.cursor-deeplink/mcp/install?name=openephemeris&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsIkBvcGVuZXBoZW1lcmlzL21jcC1zZXJ2ZXIiXSwiZW52Ijp7IkFTVFJPTUNQX1BST0ZJTEUiOiJkZXYiLCJBU1RST01DUF9CQUNLRU5EX1VSTCI6Imh0dHBzOi8vYXBpLm9wZW5lcGhlbWVyaXMuY29tIiwiQVNUUk9NQ1BfQVBJX0tFWSI6IllPVVJfQVBJX0tFWV9IRVJFIn19)
|
|
11
|
+
|
|
12
|
+
> Replace `YOUR_API_KEY_HERE` in Cursor MCP settings with your API key from https://openephemeris.com/dashboard.
|
|
13
|
+
|
|
14
|
+
Cursor deeplink payload:
|
|
15
|
+
```json
|
|
16
|
+
{
|
|
17
|
+
"command": "npx",
|
|
18
|
+
"args": [
|
|
19
|
+
"-y",
|
|
20
|
+
"@openephemeris/mcp-server"
|
|
21
|
+
],
|
|
22
|
+
"env": {
|
|
23
|
+
"ASTROMCP_PROFILE": "dev",
|
|
24
|
+
"ASTROMCP_BACKEND_URL": "https://api.openephemeris.com",
|
|
25
|
+
"ASTROMCP_API_KEY": "YOUR_API_KEY_HERE"
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
```
|
|
29
|
+
<!-- GENERATED:CURSOR_INSTALL:END -->
|
|
30
|
+
|
|
31
|
+
### Manual install (stdio MCP clients)
|
|
32
|
+
|
|
33
|
+
```json
|
|
34
|
+
{
|
|
35
|
+
"mcpServers": {
|
|
36
|
+
"openephemeris": {
|
|
37
|
+
"command": "npx",
|
|
38
|
+
"args": ["-y", "@openephemeris/mcp-server"],
|
|
39
|
+
"env": {
|
|
40
|
+
"ASTROMCP_PROFILE": "dev",
|
|
41
|
+
"ASTROMCP_BACKEND_URL": "https://api.openephemeris.com",
|
|
42
|
+
"ASTROMCP_API_KEY": "YOUR_API_KEY_HERE"
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
### Platform guide
|
|
50
|
+
|
|
51
|
+
| Client | Install mode | Config location |
|
|
52
|
+
|---|---|---|
|
|
53
|
+
| Cursor | One-click deeplink or manual | `~/.cursor/mcp.json` |
|
|
54
|
+
| Claude Desktop (macOS) | Manual | `~/Library/Application Support/Claude/claude_desktop_config.json` |
|
|
55
|
+
| Claude Desktop (Windows) | Manual | `%APPDATA%\Claude\claude_desktop_config.json` |
|
|
56
|
+
| Windsurf | Manual | `~/.codeium/windsurf/mcp_config.json` (or legacy `~/.codeium/mcp_config.json`) |
|
|
57
|
+
|
|
58
|
+
### Remote-only clients (ChatGPT Developer Mode, Antigravity, etc.)
|
|
59
|
+
|
|
60
|
+
This package runs as a local stdio MCP server. Remote-only clients require a hosted MCP endpoint (Streamable HTTP/SSE), so you must run this server behind an MCP bridge/proxy and expose it over HTTPS before adding it in those clients.
|
|
61
|
+
|
|
62
|
+
## What You Can Ask
|
|
63
|
+
|
|
64
|
+
- "Calculate a natal chart for 1990-04-15 14:30 in Chicago."
|
|
65
|
+
- "Find transit events for the next 6 months."
|
|
66
|
+
- "Get moon phase and void-of-course status right now."
|
|
67
|
+
- "Find an electional window for signing a contract next month."
|
|
68
|
+
- "Generate Human Design chart data from birth details."
|
|
69
|
+
- "Call `/predictive/transits/search` with `format=llm`."
|
|
70
|
+
|
|
71
|
+
## Tooling Model
|
|
72
|
+
|
|
73
|
+
- Typed tools are preferred for common workflows (natal, transits, moon phase, eclipse, synastry, relocation, electional, Human Design).
|
|
74
|
+
- Generic tools: `dev.list_allowed` returns all currently allowlisted operations, and `dev.call` invokes any allowlisted operation by `method + path`.
|
|
75
|
+
- Security model: default-deny with explicit allowlist in `config/dev-allowlist.json`.
|
|
76
|
+
- Deny prefixes block sensitive route families (`/auth`, `/billing`, `/admin`, etc.).
|
|
77
|
+
|
|
78
|
+
### `dev.call` input
|
|
79
|
+
|
|
80
|
+
| Parameter | Type | Required | Description |
|
|
81
|
+
|---|---|---|---|
|
|
82
|
+
| `method` | `GET\|POST\|PUT\|PATCH\|DELETE` | Yes | HTTP method |
|
|
83
|
+
| `path` | `string` | Yes | Absolute API path, e.g. `/ephemeris/natal-chart` |
|
|
84
|
+
| `query` | `object` | No | Query parameters |
|
|
85
|
+
| `body` | `object` | No | JSON body for non-GET requests |
|
|
86
|
+
| `preset` | `full\|simple` | No | Convenience mapping to `query.preset` |
|
|
87
|
+
| `format` | `json\|llm\|llm_v2` | No | Convenience mapping to `query.format` (`llm_v2` normalizes to `llm`) |
|
|
88
|
+
| `output_mode` | `full\|simple\|llm\|llm_v2` | No | Legacy compatibility field |
|
|
89
|
+
|
|
90
|
+
## Environment Variables
|
|
91
|
+
|
|
92
|
+
| Variable | Required | Description |
|
|
93
|
+
|---|---|---|
|
|
94
|
+
| `ASTROMCP_API_KEY` | Yes (unless service key/JWT used) | API key for OpenEphemeris |
|
|
95
|
+
| `ASTROMCP_BACKEND_URL` | No | Defaults to `https://api.openephemeris.com` |
|
|
96
|
+
| `ASTROMCP_PROFILE` | No | `dev` by default |
|
|
97
|
+
| `ASTROMCP_SERVICE_KEY` | No | Internal service auth |
|
|
98
|
+
| `ASTROMCP_JWT` | No | Bearer token auth |
|
|
99
|
+
| `ASTROMCP_DEV_ALLOWLIST_PATH` | No | Override allowlist file path |
|
|
100
|
+
| `MCP_USER_ID` | No | Per-instance user identifier |
|
|
101
|
+
|
|
102
|
+
Legacy aliases (`MERIDIAN_*`) remain supported.
|
|
103
|
+
|
|
104
|
+
## Development
|
|
105
|
+
|
|
106
|
+
```bash
|
|
107
|
+
npm install
|
|
108
|
+
npm run dev
|
|
109
|
+
npm run typecheck
|
|
110
|
+
npm test
|
|
111
|
+
npm run regen:dev-allowlist
|
|
112
|
+
npm run check:dev-allowlist
|
|
113
|
+
npm run sync:readme
|
|
114
|
+
npm run check:readme
|
|
115
|
+
npm run verify:release
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
`npm run verify:release` is the release gate. It checks:
|
|
119
|
+
- allowlist freshness against OpenAPI
|
|
120
|
+
- schema pack freshness
|
|
121
|
+
- README synchronization
|
|
122
|
+
- type safety + tests
|
|
123
|
+
- publish tarball contents (`npm pack --dry-run --json`)
|
|
124
|
+
|
|
125
|
+
## Architecture
|
|
126
|
+
|
|
127
|
+
```text
|
|
128
|
+
MCP Client (Cursor / Claude / Windsurf / other stdio clients)
|
|
129
|
+
| stdio JSON-RPC
|
|
130
|
+
v
|
|
131
|
+
openephemeris-mcp (Node.js)
|
|
132
|
+
| typed tools + dev.call/dev.list_allowed
|
|
133
|
+
| auth chain: Service Key > API Key > JWT
|
|
134
|
+
v
|
|
135
|
+
OpenEphemeris API
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
<!-- GENERATED:RUNTIME_SNAPSHOT:BEGIN -->
|
|
139
|
+
## Runtime Snapshot (Generated)
|
|
140
|
+
|
|
141
|
+
Generated by `npm run sync:readme` from `config/dev-allowlist.json` and the live tool registry.
|
|
142
|
+
|
|
143
|
+
- Allowlisted operations: **68**
|
|
144
|
+
- Methods: `GET=22`, `POST=46`, `PUT=0`, `PATCH=0`, `DELETE=0`
|
|
145
|
+
- Registered tools (`ASTROMCP_PROFILE=dev`): **10**
|
|
146
|
+
- Typed tools: `ephemeris.electional`, `ephemeris.moon_phase`, `ephemeris.natal_chart`, `ephemeris.next_eclipse`, `ephemeris.relocation`, `ephemeris.synastry`, `ephemeris.transits`, `human_design.chart`
|
|
147
|
+
- Generic tools: `dev.call`, `dev.list_allowed`
|
|
148
|
+
|
|
149
|
+
### Allowlist Families
|
|
150
|
+
|
|
151
|
+
| Family | Operations | Example |
|
|
152
|
+
|---|---:|---|
|
|
153
|
+
| `acg` | 5 | `POST /acg/ccg`, `GET /acg/health` |
|
|
154
|
+
| `catalogs` | 3 | `GET /catalogs/bodies`, `GET /catalogs/fixed-stars` |
|
|
155
|
+
| `comparative` | 6 | `POST /comparative/composite`, `POST /comparative/composite/midpoint` |
|
|
156
|
+
| `electional` | 5 | `GET /electional/aspect-search`, `GET /electional/find-window` |
|
|
157
|
+
| `ephemeris` | 30 | `POST /ephemeris/angles-points`, `POST /ephemeris/aspect-check` |
|
|
158
|
+
| `health` | 1 | `GET /health` |
|
|
159
|
+
| `human-design` | 6 | `POST /human-design/bodygraph`, `POST /human-design/chart` |
|
|
160
|
+
| `location` | 2 | `GET /location/autocomplete`, `GET /location/reverse` |
|
|
161
|
+
| `predictive` | 8 | `POST /predictive/events`, `POST /predictive/returns` |
|
|
162
|
+
| `timezone` | 2 | `POST /timezone/lookup`, `POST /timezone/offset` |
|
|
163
|
+
<!-- GENERATED:RUNTIME_SNAPSHOT:END -->
|