@openephemeris/mcp-server 3.1.0 → 3.2.2

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.
Files changed (58) hide show
  1. package/README.md +51 -22
  2. package/config/dev-allowlist.json +1262 -1318
  3. package/dist/index.js +0 -0
  4. package/dist/scripts/dev-allowlist.d.ts +1 -0
  5. package/dist/scripts/dev-allowlist.js +287 -0
  6. package/dist/scripts/pack-audit.d.ts +1 -0
  7. package/dist/scripts/pack-audit.js +45 -0
  8. package/dist/scripts/schema-packs.d.ts +1 -0
  9. package/dist/scripts/schema-packs.js +150 -0
  10. package/dist/scripts/smoke-dev-profile.d.ts +1 -0
  11. package/dist/scripts/smoke-dev-profile.js +25 -0
  12. package/dist/scripts/sync-readme.d.ts +1 -0
  13. package/dist/scripts/sync-readme.js +141 -0
  14. package/dist/scripts/test-client.d.ts +1 -0
  15. package/dist/scripts/test-client.js +69 -0
  16. package/dist/scripts/test-sse-client.d.ts +1 -0
  17. package/dist/scripts/test-sse-client.js +221 -0
  18. package/dist/src/auth/credentials.d.ts +65 -0
  19. package/dist/src/auth/credentials.js +200 -0
  20. package/dist/src/auth/device-auth.d.ts +56 -0
  21. package/dist/src/auth/device-auth.js +147 -0
  22. package/dist/src/backend/client.d.ts +61 -0
  23. package/dist/src/backend/client.js +335 -0
  24. package/dist/src/index.d.ts +2 -0
  25. package/dist/src/index.js +98 -0
  26. package/dist/src/schema-packs/llm.d.ts +105 -0
  27. package/dist/src/schema-packs/llm.js +429 -0
  28. package/dist/src/server-sse.d.ts +1 -0
  29. package/dist/src/server-sse.js +264 -0
  30. package/dist/src/tools/auth.d.ts +1 -0
  31. package/dist/src/tools/auth.js +202 -0
  32. package/dist/src/tools/dev.d.ts +1 -0
  33. package/dist/src/tools/dev.js +195 -0
  34. package/dist/src/tools/index.d.ts +33 -0
  35. package/dist/src/tools/index.js +56 -0
  36. package/dist/src/tools/specialized/eclipse.d.ts +1 -0
  37. package/dist/src/tools/specialized/eclipse.js +53 -0
  38. package/dist/src/tools/specialized/electional.d.ts +1 -0
  39. package/dist/src/tools/specialized/electional.js +80 -0
  40. package/dist/src/tools/specialized/human_design.d.ts +1 -0
  41. package/dist/src/tools/specialized/human_design.js +54 -0
  42. package/dist/src/tools/specialized/moon.d.ts +1 -0
  43. package/dist/src/tools/specialized/moon.js +51 -0
  44. package/dist/src/tools/specialized/natal.d.ts +1 -0
  45. package/dist/src/tools/specialized/natal.js +80 -0
  46. package/dist/src/tools/specialized/relocation.d.ts +1 -0
  47. package/dist/src/tools/specialized/relocation.js +76 -0
  48. package/dist/src/tools/specialized/synastry.d.ts +1 -0
  49. package/dist/src/tools/specialized/synastry.js +73 -0
  50. package/dist/src/tools/specialized/transits.d.ts +1 -0
  51. package/dist/src/tools/specialized/transits.js +87 -0
  52. package/dist/test/allowlist-and-tools.test.d.ts +1 -0
  53. package/dist/test/allowlist-and-tools.test.js +96 -0
  54. package/dist/test/backend-client.test.d.ts +1 -0
  55. package/dist/test/backend-client.test.js +284 -0
  56. package/dist/test/credentials.test.d.ts +1 -0
  57. package/dist/test/credentials.test.js +143 -0
  58. package/package.json +27 -18
package/README.md CHANGED
@@ -7,7 +7,7 @@ Model Context Protocol server for OpenEphemeris. This package exposes typed astr
7
7
  ### One-click install (Cursor)
8
8
 
9
9
  <!-- GENERATED:CURSOR_INSTALL:BEGIN -->
10
- [![Install in Cursor](https://img.shields.io/badge/Install%20in-Cursor-1f6feb)](cursor://anysphere.cursor-deeplink/mcp/install?name=openephemeris&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsIkBvcGVuZXBoZW1lcmlzL21jcC1zZXJ2ZXIiXSwiZW52Ijp7IkFTVFJPTUNQX1BST0ZJTEUiOiJkZXYiLCJBU1RST01DUF9CQUNLRU5EX1VSTCI6Imh0dHBzOi8vYXBpLm9wZW5lcGhlbWVyaXMuY29tIiwiQVNUUk9NQ1BfQVBJX0tFWSI6IllPVVJfQVBJX0tFWV9IRVJFIn19)
10
+ [![Install in Cursor](https://img.shields.io/badge/Install%20in-Cursor-1f6feb)](cursor://anysphere.cursor-deeplink/mcp/install?name=openephemeris&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsIkBvcGVuZXBoZW1lcmlzL21jcC1zZXJ2ZXIiXSwiZW52Ijp7Ik9QRU5FUEhFTUVSSVNfUFJPRklMRSI6ImRldiIsIk9QRU5FUEhFTUVSSVNfQkFDS0VORF9VUkwiOiJodHRwczovL2FwaS5vcGVuZXBoZW1lcmlzLmNvbSIsIk9QRU5FUEhFTUVSSVNfQVBJX0tFWSI6IllPVVJfQVBJX0tFWV9IRVJFIn19)
11
11
 
12
12
  > Replace `YOUR_API_KEY_HERE` in Cursor MCP settings with your API key from https://openephemeris.com/dashboard.
13
13
 
@@ -20,9 +20,9 @@ Cursor deeplink payload:
20
20
  "@openephemeris/mcp-server"
21
21
  ],
22
22
  "env": {
23
- "ASTROMCP_PROFILE": "dev",
24
- "ASTROMCP_BACKEND_URL": "https://api.openephemeris.com",
25
- "ASTROMCP_API_KEY": "YOUR_API_KEY_HERE"
23
+ "OPENEPHEMERIS_PROFILE": "dev",
24
+ "OPENEPHEMERIS_BACKEND_URL": "https://api.openephemeris.com",
25
+ "OPENEPHEMERIS_API_KEY": "YOUR_API_KEY_HERE"
26
26
  }
27
27
  }
28
28
  ```
@@ -37,9 +37,9 @@ Cursor deeplink payload:
37
37
  "command": "npx",
38
38
  "args": ["-y", "@openephemeris/mcp-server"],
39
39
  "env": {
40
- "ASTROMCP_PROFILE": "dev",
41
- "ASTROMCP_BACKEND_URL": "https://api.openephemeris.com",
42
- "ASTROMCP_API_KEY": "YOUR_API_KEY_HERE"
40
+ "OPENEPHEMERIS_PROFILE": "dev",
41
+ "OPENEPHEMERIS_BACKEND_URL": "https://api.openephemeris.com",
42
+ "OPENEPHEMERIS_API_KEY": "YOUR_API_KEY_HERE"
43
43
  }
44
44
  }
45
45
  }
@@ -48,6 +48,8 @@ Cursor deeplink payload:
48
48
 
49
49
  ### Platform guide
50
50
 
51
+ > **Detailed setup walkthroughs** for each platform are in [SETUP.md](./SETUP.md).
52
+
51
53
  | Client | Install mode | Config location |
52
54
  |---|---|---|
53
55
  | Cursor | One-click deeplink or manual | `~/.cursor/mcp.json` |
@@ -112,15 +114,20 @@ This package runs as a local stdio MCP server. Remote-only clients require a hos
112
114
 
113
115
  | Variable | Required | Description |
114
116
  |---|---|---|
115
- | `ASTROMCP_API_KEY` | Yes (unless service key/JWT used) | API key for OpenEphemeris |
116
- | `ASTROMCP_BACKEND_URL` | No | Defaults to `https://api.openephemeris.com` |
117
- | `ASTROMCP_PROFILE` | No | `dev` by default |
118
- | `ASTROMCP_SERVICE_KEY` | No | Internal service auth |
119
- | `ASTROMCP_JWT` | No | Bearer token auth |
120
- | `ASTROMCP_DEV_ALLOWLIST_PATH` | No | Override allowlist file path |
117
+ | `OPENEPHEMERIS_API_KEY` | Yes (unless service key/JWT used) | API key for OpenEphemeris |
118
+ | `ASTROMCP_API_KEY` | No | Legacy alias for `OPENEPHEMERIS_API_KEY` (checked as fallback) |
119
+ | `OPENEPHEMERIS_BACKEND_URL` | No | Defaults to `https://api.openephemeris.com` |
120
+ | `OPENEPHEMERIS_PROFILE` | No | `dev` by default |
121
+ | `OPENEPHEMERIS_SERVICE_KEY` | No | Internal service auth |
122
+ | `OPENEPHEMERIS_JWT` | No | Bearer token auth |
123
+ | `OPENEPHEMERIS_DEV_ALLOWLIST_PATH` | No | Override allowlist file path |
121
124
  | `MCP_USER_ID` | No | Per-instance user identifier |
122
125
 
123
- Legacy aliases (`MERIDIAN_*`) remain supported.
126
+ Legacy aliases (`ASTROMCP_*`, `MERIDIAN_*`) remain supported.
127
+
128
+ ## Legal
129
+
130
+ This package is licensed under the [MIT License](./LICENSE). However, use of this package to access the OpenEphemeris API constitutes use of the Service and is governed by the [OpenEphemeris Terms of Service](https://openephemeris.com/terms). By using this package, you agree to those terms. See also the [Privacy Policy](https://openephemeris.com/privacy) and [Acceptable Use Policy](https://openephemeris.com/acceptable-use).
124
131
 
125
132
  ## Development
126
133
 
@@ -136,6 +143,15 @@ npm run check:readme
136
143
  npm run verify:release
137
144
  ```
138
145
 
146
+ ### Deploying the SSE Server to Fly.io
147
+
148
+ When you update the MCP server logic (handlers, bug fixes, hardening), you should deploy it so clients connecting via our remote `https://mcp.openephemeris.com/sse` endpoint get the updates immediately.
149
+
150
+ 1. Navigate to `apps/api/mcp-server`
151
+ 2. Run `fly deploy --remote-only`
152
+
153
+ *Note on NPM:* Deploying to Fly.io instantly updates the web-accessible SSE tool. However, users installing your tool locally in Cursor/Desktop via `npx @openephemeris/mcp-server` will *only* receive the updates once a new version is published to NPM. If your changes are critical, you should bump the version in `package.json` and run `npm publish` (or your CI release pipeline) *after* deploying to Fly.
154
+
139
155
  `npm run verify:release` is the release gate. It checks:
140
156
  - allowlist freshness against OpenAPI
141
157
  - schema pack freshness
@@ -161,25 +177,38 @@ OpenEphemeris API
161
177
 
162
178
  Generated by `npm run sync:readme` from `config/dev-allowlist.json` and the live tool registry.
163
179
 
164
- - Allowlisted operations: **67**
165
- - Methods: `GET=22`, `POST=45`, `PUT=0`, `PATCH=0`, `DELETE=0`
166
- - Registered tools (`ASTROMCP_PROFILE=dev`): **10**
167
- - Typed tools: `ephemeris.electional`, `ephemeris.moon_phase`, `ephemeris.natal_chart`, `ephemeris.next_eclipse`, `ephemeris.relocation`, `ephemeris.synastry`, `ephemeris.transits`, `human_design.chart`
168
- - Generic tools: `dev.call`, `dev.list_allowed`
180
+ - Allowlisted operations: **97**
181
+ - Methods: `GET=41`, `POST=56`, `PUT=0`, `PATCH=0`, `DELETE=0`
182
+ - Registered tools (`OPENEPHEMERIS_PROFILE=dev`): **13**
183
+ - Typed tools: `auth_login`, `auth_logout`, `auth_status`, `dev_call`, `dev_list_allowed`, `ephemeris_electional`, `ephemeris_moon_phase`, `ephemeris_natal_chart`, `ephemeris_next_eclipse`, `ephemeris_relocation`, `ephemeris_synastry`, `ephemeris_transits`, `human_design_chart`
184
+ - Generic tools:
169
185
 
170
186
  ### Allowlist Families
171
187
 
172
188
  | Family | Operations | Example |
173
189
  |---|---:|---|
174
- | `acg` | 4 | `POST /acg/ccg`, `GET /acg/health` |
190
+ | `acg` | 12 | `POST /acg/aspects`, `POST /acg/ccg` |
191
+ | `calendar` | 3 | `GET /calendar/astrology/cross-quarter`, `GET /calendar/astrology/lunar-standstill` |
175
192
  | `catalogs` | 3 | `GET /catalogs/bodies`, `GET /catalogs/fixed-stars` |
193
+ | `chinese` | 2 | `POST /chinese/bazi`, `GET /chinese/zodiac` |
176
194
  | `comparative` | 5 | `POST /comparative/composite`, `POST /comparative/composite/midpoint` |
195
+ | `eclipse` | 5 | `GET /eclipse/besselian-elements`, `GET /eclipse/lunar/global` |
177
196
  | `electional` | 5 | `GET /electional/aspect-search`, `GET /electional/find-window` |
178
- | `ephemeris` | 29 | `POST /ephemeris/angles-points`, `POST /ephemeris/aspect-check` |
197
+ | `ephemeris` | 33 | `GET /ephemeris/agro/calendar`, `GET /ephemeris/agro/daily` |
179
198
  | `health` | 1 | `GET /health` |
180
- | `human-design` | 6 | `POST /human-design/bodygraph`, `POST /human-design/chart` |
199
+ | `human-design` | 5 | `POST /human-design/chart`, `POST /human-design/composite` |
181
200
  | `location` | 2 | `GET /location/autocomplete`, `GET /location/reverse` |
182
201
  | `predictive` | 8 | `POST /predictive/events`, `POST /predictive/returns` |
202
+ | `tidal` | 2 | `GET /tidal/forcing`, `GET /tidal/forcing/deep-time` |
203
+ | `time` | 6 | `GET /time/delta-t`, `GET /time/equation-of-time` |
183
204
  | `timezone` | 2 | `POST /timezone/lookup`, `POST /timezone/offset` |
205
+ | `vedic` | 1 | `POST /vedic/chart` |
184
206
  | `visualization` | 2 | `POST /visualization/bi-wheel`, `POST /visualization/chart-wheel` |
185
207
  <!-- GENERATED:RUNTIME_SNAPSHOT:END -->
208
+
209
+
210
+ NPM publish
211
+
212
+ publish from /c/src/openephemeris/apps/api/mcp-server
213
+ npm login
214
+ npm publish