mcp-google-api 0.22.1 → 0.25.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/CHANGELOG.md +232 -3
- package/README.md +33 -11
- package/bin/mcp-google-api.mjs +53 -0
- package/dist/cli.d.ts +1 -1
- package/dist/cli.js +181 -92
- package/dist/cli.js.map +1 -1
- package/package.json +6 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,7 +1,120 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
## [0.
|
|
3
|
+
## [0.25.0](https://github.com/Ogekuri/mcp-google-api/compare/v0.24.0..v0.25.0) - 2026-11-08
|
|
4
4
|
### 🐛 Bug Fixes
|
|
5
|
+
- make doctor spawn tests hermetic with isolated home [useReq] *(cliSpawn)*
|
|
6
|
+
- Root cause of the CI-only failure: the doctor spawn test inherited the
|
|
7
|
+
- host HOME, so it read the developer machine's real
|
|
8
|
+
- ~/.config/mcp-google-api/config.json; locally the real API key made the
|
|
9
|
+
- REQ-070 api-key check pass (exit 0), while the clean CI runner had no
|
|
10
|
+
- settings file, so doctor correctly exited 1 and the gate failed.
|
|
11
|
+
- spawnCli now accepts an injectable HOME override; the doctor success
|
|
12
|
+
- test provisions an isolated home with the DES-018 settings fixture and
|
|
13
|
+
- a valid-format test key, so local runs reproduce the CI runner state
|
|
14
|
+
- exactly and the discrepancy can no longer hide before publication.
|
|
15
|
+
- Add a REQ-070 regression pin: doctor exits 1 on a clean isolated home
|
|
16
|
+
- without a configured API key (the exact CI failure state).
|
|
17
|
+
- Evidence: clean-HOME reproduction exited 1 with api-key fail before the
|
|
18
|
+
- fix; after the fix the suite passes 4/4 both with the real and a clean
|
|
19
|
+
- HOME; full suite 146/146; local pre-release gate green (exit 0).
|
|
20
|
+
- No source changes: doctor clean-env exit-1 behavior is REQ-070-correct.
|
|
21
|
+
|
|
22
|
+
## [0.24.0](https://github.com/Ogekuri/mcp-google-api/compare/v0.23.0..v0.24.0) - 2026-11-08
|
|
23
|
+
### ⛰️ Features
|
|
24
|
+
- add pre-release-check.sh release gate [useReq] *(scripts)*
|
|
25
|
+
- Ship scripts/pre-release-check.sh running the release-gating stages
|
|
26
|
+
- in mandatory order: publish-version guard, typecheck, unit tests,
|
|
27
|
+
- production build, aborting at the first failed stage (PKG-058/059).
|
|
28
|
+
- The script exits 0 only when every stage passes, runs from any cwd
|
|
29
|
+
- by resolving the repository root, and never installs dependencies
|
|
30
|
+
- or publishes (PKG-060).
|
|
31
|
+
- Add tests/preReleaseCheck.unit.test.ts (TST-024): static contract on
|
|
32
|
+
- stage order, fail-fast wiring, repository-root cd, and no install/
|
|
33
|
+
- publish commands, plus a sandbox run proving fail-fast exit 1 on an
|
|
34
|
+
- injected failing stage.
|
|
35
|
+
- Runtime verification: full run green (guard 0.23.0 publishable,
|
|
36
|
+
- typecheck clean, 143/143 unit tests, build success, exit 0); real
|
|
37
|
+
- fail-fast observed on a missing-toolchain run (typecheck FAILED ->
|
|
38
|
+
- exit 1, later stages skipped).
|
|
39
|
+
|
|
40
|
+
### 🐛 Bug Fixes
|
|
41
|
+
- sync package-lock bin path with package.json launcher [useReq] *(packaging)*
|
|
42
|
+
- The committed package-lock.json root bin entry still recorded the
|
|
43
|
+
- superseded dist/cli.js launcher, so every standard bootstrap
|
|
44
|
+
- (npm install) rewrote the tracked lockfile and left a fresh clone dirty.
|
|
45
|
+
- Regenerate the lockfile bin entry to bin/mcp-google-api.mjs, matching
|
|
46
|
+
- the package.json launcher contract (PRJ-020).
|
|
47
|
+
- Add a level-0 regression guard test asserting lockfile/package.json
|
|
48
|
+
- bin-map identity to tests/npmPublishContract.unit.test.ts, closing
|
|
49
|
+
- the TST-021 coverage gap that let the drift go undetected.
|
|
50
|
+
- Evidence: reproducer red on the stale lockfile, green after the fix;
|
|
51
|
+
- full suite 138/138 pass, typecheck clean, static analysis clean.
|
|
52
|
+
|
|
53
|
+
### 🚜 Changes
|
|
54
|
+
- gate pipeline on pre-release test checks [useReq] *(release)*
|
|
55
|
+
- Add a Pre-release check step to .github/workflows/release-npm.yml
|
|
56
|
+
- running scripts/pre-release-check.sh after npm ci and before every
|
|
57
|
+
- build, pack, publish, and release-creation step, so versions whose
|
|
58
|
+
- tests fail produce no release artifact and are never published
|
|
59
|
+
- (PKG-063).
|
|
60
|
+
- The gate executes the PKG-058 stages (publish-version guard,
|
|
61
|
+
- typecheck, unit tests, build) in fail-fast order (PKG-059) and never
|
|
62
|
+
- installs dependencies or publishes (PKG-060).
|
|
63
|
+
- Update the workflow header and pack-step comments; the release
|
|
64
|
+
- pipeline defines no direct test commands - all test stages live in
|
|
65
|
+
- the gate script.
|
|
66
|
+
- SRS: add PKG-063 and extend TST-020 with the gate contract.
|
|
67
|
+
- Tests: ciContract asserts gate presence, placement, and absence of
|
|
68
|
+
- direct test commands; suite 6/6, full suite 145/145.
|
|
69
|
+
- clean run-created artifacts in pre-release-check [useReq] *(scripts)*
|
|
70
|
+
- scripts/pre-release-check.sh now snapshots the repository state before
|
|
71
|
+
- the stages and removes on exit every artifact directory the run created
|
|
72
|
+
- (e.g. the tsup dist/ tree), on both success and fail-fast paths, so the
|
|
73
|
+
- repository is left as found (PKG-061).
|
|
74
|
+
- Pre-existing artifact directories are preserved untouched (PKG-062).
|
|
75
|
+
- SRS: add PKG-061/PKG-062 and extend TST-024 with the cleanup contract.
|
|
76
|
+
- Tests: shared sandbox helper plus two behavioral proofs - run-created
|
|
77
|
+
- dist removed on the fail-fast path, pre-existing dist sentinel intact.
|
|
78
|
+
- Verification: suite 7/7; full run 145/145 tests with dist removed after
|
|
79
|
+
- the run; pre-existing dist preserved in a second scenario; static
|
|
80
|
+
- analysis clean; git status clean after every run.
|
|
81
|
+
|
|
82
|
+
## [0.23.0](https://github.com/Ogekuri/mcp-google-api/compare/v0.22.0..v0.23.0) - 2026-11-07
|
|
83
|
+
### ⛰️ Features
|
|
84
|
+
- add copilot CLI agent support (DES-017, REQ-110/112/113/117) [useReq] *(cli-targets)*
|
|
85
|
+
- Requirements: extend DES-017, REQ-110, REQ-112, REQ-113, REQ-117 with the copilot target
|
|
86
|
+
- Source: add COPILOT_TARGET adapter (~/.copilot/mcp.json JSON mcpServers + ~/.copilot/skills) to CLI_TARGETS registry in src/utils/cliTargets.ts
|
|
87
|
+
- Docs: README supported-agents list/table and WORKFLOW/REFERENCES runtime model updated
|
|
88
|
+
- Verification: eslint/tsc clean, npm test 132/132 pass, enable/show/install runtime smoke on isolated HOME
|
|
89
|
+
|
|
90
|
+
### 🐛 Bug Fixes
|
|
91
|
+
- build dist via prepare lifecycle for GitHub installs [useReq] *(packaging)*
|
|
92
|
+
- Develop-channel installs (npm install -g github:Ogekuri/mcp-google-api#<tag>,
|
|
93
|
+
- REQ-171) packed the fetched git tree without dist/: no build lifecycle ran, so
|
|
94
|
+
- every installed package hit the PRJ-021 remediation error and the post-upgrade
|
|
95
|
+
- install child failed (evidence: v0.22.4 pack listing had 0 dist entries).
|
|
96
|
+
- package.json: declare scripts.prepare = npm run build so npm git-dep
|
|
97
|
+
- preparation builds dist/ into the packed tarball (PRJ-020; verified by
|
|
98
|
+
- local git-sim packs: 8 dist entries incl. dist/cli.js).
|
|
99
|
+
- tests/npmPublishContract.unit.test.ts: add failing-first reproducer test
|
|
100
|
+
- pinning the prepare lifecycle contract (no chained installs, PKG-019) and
|
|
101
|
+
- restore deterministic pack listing via --ignore-scripts.
|
|
102
|
+
- usereq/docs/WORKFLOW.md: document the prepare build inside EDGE-09.
|
|
103
|
+
- spawn package-manager child with neutral home cwd [useReq] *(upgrade)*
|
|
104
|
+
- Defect: --upgrade (npm and --dev|--develop channels) and --uninstall
|
|
105
|
+
- spawned npm from the caller's working directory. When invoked from the
|
|
106
|
+
- source checkout of the same package (scripts/mcp-google-api.sh cd's to
|
|
107
|
+
- the repo root), npm reconciled the git-ref global install against that
|
|
108
|
+
- same-name local project and corrupted reify: TAR_ENTRY_ERROR ENOENT
|
|
109
|
+
- floods on hono/@modelcontextprotocol/sdk/@grpc/grpc-js plus a fatal
|
|
110
|
+
- lifecycle 'spawn sh ENOENT' (protobufjs) against a cwd deleted
|
|
111
|
+
- mid-reify.
|
|
112
|
+
- Fix: runPackageManagerCommand spawns the child with cwd = os.homedir()
|
|
113
|
+
- (explicit neutral directory, env/prefix unchanged); stdio inheritance,
|
|
114
|
+
- exit propagation, and the REQ-128 manual-command hint are unchanged.
|
|
115
|
+
- Reproducer test (HDT Level 1) added to tests/upgradeManager.unit.test.ts:
|
|
116
|
+
- asserts the child cwd is the user home and never the caller cwd; suite
|
|
117
|
+
- went 11 pass / 1 fail before the fix to 136/136 after.
|
|
5
118
|
- report skipped server-start dispatch with build remediation [useReq] *(cli)*
|
|
6
119
|
- Root cause of the persistent pi 'MCP connection closed' after the 0.21.0 rename:
|
|
7
120
|
- the REQ-114 launcher 'npx -y mcp-google-api start --stdio' resolves a same-name
|
|
@@ -16,6 +129,118 @@
|
|
|
16
129
|
- Document the stale-artifact remediation in docs/CONFIGURATION.md; update
|
|
17
130
|
- WORKFLOW.md TRACE-A/EDGE-06 and regenerate REFERENCES.md.
|
|
18
131
|
|
|
132
|
+
### 🚜 Changes
|
|
133
|
+
- make --upgrade update unconditionally [useReq] *(upgradeManager)*
|
|
134
|
+
- --upgrade now reinstalls mcp-google-api@latest in every invocation,
|
|
135
|
+
- without any pre-upgrade version comparison (REQ-146 rewrite).
|
|
136
|
+
- Removed the pre-upgrade registry necessity check and the
|
|
137
|
+
- already-latest skip path (REQ-144, REQ-145, REQ-147 deleted) and the
|
|
138
|
+
- pre-upgrade-latest summary shortcut (REQ-181 deleted); REQ-172
|
|
139
|
+
- reworded since the comparison no longer exists.
|
|
140
|
+
- The summary updated version now comes from the post-upgrade probe
|
|
141
|
+
- (REQ-134); unused isUpgradeNecessary removed.
|
|
142
|
+
- Requirements, workflow model, and references updated; typecheck and
|
|
143
|
+
- 136 unit tests pass.
|
|
144
|
+
- self-heal npm reify ENOENT in --upgrade [useReq] *(upgradeManager)*
|
|
145
|
+
- --upgrade update children (npm and --develop/--dev channels) run with
|
|
146
|
+
- captured output echoed on stderr (REQ-125, REQ-171).
|
|
147
|
+
- A non-zero exit carrying an ENOENT reify diagnostic triggers one
|
|
148
|
+
- tolerated npm uninstall -g clean-slate child plus a single retry,
|
|
149
|
+
- repairing corrupted global trees whose dependency lifecycle spawns
|
|
150
|
+
- fail like the reported 'spawn sh ENOENT' (REQ-182, REQ-183).
|
|
151
|
+
- Requirements, workflow model, and references updated; typecheck and
|
|
152
|
+
- 136 unit tests pass.
|
|
153
|
+
- resolve npmjs latest via packument manifest [useReq] *(upgradeManager)*
|
|
154
|
+
- --ver/--version now probe the npm packument manifest with the
|
|
155
|
+
- abbreviated Accept header and print dist-tags.latest (REQ-179, REQ-180).
|
|
156
|
+
- --upgrade reports the pre-upgrade npmjs latest as the summary updated
|
|
157
|
+
- version and skips the post-upgrade probe when resolved (REQ-181).
|
|
158
|
+
- REQUIREMENTS/WORKFLOW/REFERENCES updated; typecheck and 136 unit
|
|
159
|
+
- tests pass.
|
|
160
|
+
- ship mcp-google-api launcher bin with remediation [useReq] *(bin)*
|
|
161
|
+
- PRJ-020: the installed mcp-google-api bin executes the packaged
|
|
162
|
+
- dist/cli.js Node entry forwarding every argument unchanged with no
|
|
163
|
+
- implicit install/build steps (analogous to scripts/mcp-google-api.sh).
|
|
164
|
+
- PRJ-021: new launcher bin/mcp-google-api.mjs (realpath-safe package-root
|
|
165
|
+
- resolution) prints JSON build-remediation guidance on stderr and exits
|
|
166
|
+
- non-zero when dist/cli.js is missing - impossible to deliver from the
|
|
167
|
+
- built artifact itself.
|
|
168
|
+
- package.json: bin repointed to bin/mcp-google-api.mjs; files allowlist
|
|
169
|
+
- ships bin/ (verified in npm pack --dry-run); .gitignore gains !bin/
|
|
170
|
+
- exceptions (CTN-010).
|
|
171
|
+
- PKG-038 publication fixture updated for the bin/ prefix; verified live:
|
|
172
|
+
- launcher forwards (--help, exit 0) and remediates (exit 1, JSON stderr);
|
|
173
|
+
- 136/136 tests, typecheck and eslint clean.
|
|
174
|
+
- add develop-channel coverage for --upgrade --dev|--develop [useReq] *(test)*
|
|
175
|
+
- TST-023: new test requirement mapping REQ-170/171/172/173/177/178 to
|
|
176
|
+
- tests/upgradeManager.unit.test.ts.
|
|
177
|
+
- HDT Level 0: buildDevelopUpgradeCommand builds the raw tag install
|
|
178
|
+
- command npm install -g github:Ogekuri/mcp-google-api#<tag>.
|
|
179
|
+
- HDT Level 1: the develop channel probes only the GitHub releases
|
|
180
|
+
- endpoint bypassing the idle cache (REQ-177), spawns the tagged install
|
|
181
|
+
- with the raw tag_name (REQ-171), always proceeds even when the probed
|
|
182
|
+
- tag equals the installed version (REQ-172), reports the probed version
|
|
183
|
+
- in the summary (REQ-173), and fails fast on probe error without
|
|
184
|
+
- spawning any child process (REQ-178).
|
|
185
|
+
- No src/ changes: verification confirmed the implementation already
|
|
186
|
+
- satisfied the request; 135/135 tests, typecheck and eslint clean.
|
|
187
|
+
- move publish guard to tools/ with gitignore exception [useReq] *(tools)*
|
|
188
|
+
- Move scripts/check-publish-version.mjs to tools/ (PKG-057 updated):
|
|
189
|
+
- the ../package.json resolution keeps working at the same directory
|
|
190
|
+
- depth; guard verified executable from the new path (exit 0).
|
|
191
|
+
- Wire package.json check:publish-version to the new path; the
|
|
192
|
+
- prepublishOnly chain (PKG-005, PKG-017) is unchanged.
|
|
193
|
+
- .gitignore: append !tools/ and !tools/**/* at the tail of the
|
|
194
|
+
- negated-inclusion included-paths section (CTN-009); git check-ignore
|
|
195
|
+
- confirms the guard is version-controlled.
|
|
196
|
+
- requirements: scripts/ tree entry reduced to the mcp-google-api.sh
|
|
197
|
+
- launcher; tools/ entry added for the publish guard.
|
|
198
|
+
- BREAKING CHANGE: remove redundant shell helpers, document HTTP vs stdio [useReq] *(scripts)*
|
|
199
|
+
- Delete scripts/build.sh, start-http.sh, start-mcp.sh, test.sh: thin
|
|
200
|
+
- wrappers over npm run build/start/test/test:e2e; PKG-019 keeps the
|
|
201
|
+
- single npm run verify pipeline and REQ-094 forbids implicit builds.
|
|
202
|
+
- scripts/ now holds only mcp-google-api.sh (PRJ-018, PRJ-019) and the
|
|
203
|
+
- retained check-publish-version.mjs publish guard: required prepublishOnly
|
|
204
|
+
- stage, not an end-user accessory (PKG-057, PKG-005, PKG-017).
|
|
205
|
+
- README: new 'stdio vs Streamable HTTP' comparison section (PKG-054,
|
|
206
|
+
- PKG-055, PKG-056).
|
|
207
|
+
- Remove the obsolete start-mcp.sh remediation test whose subject was
|
|
208
|
+
- deleted; no src/ changes, WORKFLOW.md unaffected.
|
|
209
|
+
- --dev|--develop installs the latest tagged GitHub release [useReq] *(upgrade)*
|
|
210
|
+
- REQ-170..173: --upgrade --develop|--dev now selects the latest tagged
|
|
211
|
+
- GitHub release regardless of the branch carrying the tag; REQ-177 adds
|
|
212
|
+
- the forced releases-API probe bypassing the idle cache gate; REQ-178
|
|
213
|
+
- fails fast with a stderr diagnostic and no child spawn on probe failure.
|
|
214
|
+
- upgradeManager: GITHUB_UPGRADE_REPOSITORY + buildDevelopUpgradeCommand(tag)
|
|
215
|
+
- replace PACKAGE_DEVELOP_UPGRADE_COMMAND; develop branch probes GitHub first,
|
|
216
|
+
- installs github:Ogekuri/mcp-google-api#<tag>, and reports the probed version.
|
|
217
|
+
- autoUpdate: GitHubLatestVersionProbe ok outcome now carries the raw tag_name.
|
|
218
|
+
- cli: help text and dispatch comments document the new channel semantics.
|
|
219
|
+
- BREAKING CHANGE: remove legacy exec aliases, placeholder key, entry-gate fallback [useReq] *(cli)*
|
|
220
|
+
- BREAKING: exec accepts only canonical maps_ tool names (REQ-073); short/snake_case/batch-geocode-tool aliases removed from EXEC_TOOLS, execTool switch, help examples, and README.
|
|
221
|
+
- BREAKING: legacy INSTALL_API_KEY_PLACEHOLDER config value no longer loads as unset (DES-023, REQ-142); empty values still do.
|
|
222
|
+
- BREAKING: superseded isRunDirectly basename entry-gate removed; isEntryMainModule() alone decides dispatch.
|
|
223
|
+
- DOCTOR_PROBES use canonical tool names; tests canonicalized per user-requested legacy removal.
|
|
224
|
+
- Verified: typecheck, static-check clean, npm test 132/132; exec geocode now rejected as unknown tool.
|
|
225
|
+
- make --help user-facing and document --develop/--dev [useReq] *(cli)*
|
|
226
|
+
- REQ-174: help descriptions limited to user-facing usage; removed internal details (persisted configuration, settings file, dispatch order, dist/cli.js path).
|
|
227
|
+
- REQ-175: --upgrade epilog documents the --develop | --dev GitHub develop-branch option.
|
|
228
|
+
- REQ-176: --ver described accurately as installed, npmjs-latest, and GitHub-latest versions.
|
|
229
|
+
- Verified facts kept: exec alias list (batch-geocode-tool) and search-nearby example params match the schema.
|
|
230
|
+
- Verified: static-check clean, npm test 132/132 (help contract REQ-129/130/131 intact).
|
|
231
|
+
- add --develop/--dev GitHub develop-branch upgrade channel [useReq] *(upgrade-manager)*
|
|
232
|
+
- REQ-170..173: --upgrade accepts --develop with equivalent --dev alias selecting the GitHub develop branch.
|
|
233
|
+
- REQ-125/REQ-144 scoped to the default npm channel; develop channel skips the registry gate and already-latest path.
|
|
234
|
+
- upgradeManager: UpgradeChannel, PACKAGE_DEVELOP_UPGRADE_COMMAND (npm install -g github:Ogekuri/mcp-google-api#develop), parseUpgradeChannel; parseManagementCommand accepts the --upgrade + --develop/--dev pair.
|
|
235
|
+
- Develop-channel summary reports unknown as the updated version; default npm path unchanged.
|
|
236
|
+
- WORKFLOW.md TRACE-A/L and EDGE-07/09 updated; REFERENCES.md regenerated.
|
|
237
|
+
- Verified: typecheck, static-check clean, npm test 132/132.
|
|
238
|
+
- encode README header block structure and centered quick index [useReq] *(readme)*
|
|
239
|
+
- Add requirements PKG-046..PKG-053: [!CAUTION] pre-header, exact title format, centered badge/description/quick-index/status blocks, fixed H1 section order, quick-start step order.
|
|
240
|
+
- Rebuild README header: centered description block (strong summary + br + detail), HTML quick-index anchors now including Requirements, single status+notice centered block.
|
|
241
|
+
- No source-code change; WORKFLOW.md runtime model unaffected; REFERENCES.md regenerated unchanged.
|
|
242
|
+
- Verified: static-check clean; npm test 132/132 pass.
|
|
243
|
+
|
|
19
244
|
## [0.22.0](https://github.com/Ogekuri/mcp-google-api/compare/v0.21.0..v0.22.0) - 2026-11-06
|
|
20
245
|
### 🐛 Bug Fixes
|
|
21
246
|
- symlink-aware main-module gate restores CLI dispatch [useReq] *(cli)*
|
|
@@ -409,7 +634,9 @@
|
|
|
409
634
|
- \[0.20.0\]: https://github.com/Ogekuri/mcp-google-api/releases/tag/v0.20.0
|
|
410
635
|
- \[0.21.0\]: https://github.com/Ogekuri/mcp-google-api/releases/tag/v0.21.0
|
|
411
636
|
- \[0.22.0\]: https://github.com/Ogekuri/mcp-google-api/releases/tag/v0.22.0
|
|
412
|
-
- \[0.
|
|
637
|
+
- \[0.23.0\]: https://github.com/Ogekuri/mcp-google-api/releases/tag/v0.23.0
|
|
638
|
+
- \[0.24.0\]: https://github.com/Ogekuri/mcp-google-api/releases/tag/v0.24.0
|
|
639
|
+
- \[0.25.0\]: https://github.com/Ogekuri/mcp-google-api/releases/tag/v0.25.0
|
|
413
640
|
|
|
414
641
|
[0.2.0]: https://github.com/Ogekuri/mcp-google-api/releases/tag/v0.2.0
|
|
415
642
|
[0.3.0]: https://github.com/Ogekuri/mcp-google-api/compare/v0.2.0..v0.3.0
|
|
@@ -431,4 +658,6 @@
|
|
|
431
658
|
[0.20.0]: https://github.com/Ogekuri/mcp-google-api/compare/v0.19.0..v0.20.0
|
|
432
659
|
[0.21.0]: https://github.com/Ogekuri/mcp-google-api/compare/v0.20.0..v0.21.0
|
|
433
660
|
[0.22.0]: https://github.com/Ogekuri/mcp-google-api/compare/v0.21.0..v0.22.0
|
|
434
|
-
[0.
|
|
661
|
+
[0.23.0]: https://github.com/Ogekuri/mcp-google-api/compare/v0.22.0..v0.23.0
|
|
662
|
+
[0.24.0]: https://github.com/Ogekuri/mcp-google-api/compare/v0.23.0..v0.24.0
|
|
663
|
+
[0.25.0]: https://github.com/Ogekuri/mcp-google-api/compare/v0.24.0..v0.25.0
|
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
> * **No Support or Feature Requests:** please **do not** open issues, bug reports, or feature requests. They will not be addressed or accepted at this stage.
|
|
11
11
|
> * **No Warranty:** this software is provided **"AS IS"**, without warranty of any kind, express or implied. Use it strictly for testing and evaluation purposes at your own sole risk.
|
|
12
12
|
|
|
13
|
-
# mcp-google-api / MCP Google API server (0.
|
|
13
|
+
# mcp-google-api / MCP Google API server (0.25.0)
|
|
14
14
|
|
|
15
15
|
<p align="center">
|
|
16
16
|
<img src="https://img.shields.io/badge/node-%3E%3D24-339933?style=flat-square&logo=nodedotjs&logoColor=white" alt="Node.js >= 24">
|
|
@@ -19,15 +19,25 @@
|
|
|
19
19
|
<img src="https://img.shields.io/badge/platform-Windows%20%7C%20macOS%20%7C%20Linux-6A7EC2?style=flat-square&logo=terminal&logoColor=white" alt="Platforms">
|
|
20
20
|
</p>
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
22
|
+
<p align="center">
|
|
23
|
+
<strong>MCP Google API server — Google APIs for AI agents over the <a href="https://modelcontextprotocol.io">Model Context Protocol</a></strong>
|
|
24
|
+
<br>
|
|
25
|
+
The server exposes Google API families to AI agents over stdio or Streamable HTTP. The currently implemented family is <strong>Google Maps</strong>, providing 18 read-only tools: geocoding and reverse geocoding, Places API (New) text/nearby search with server-side filters (<code>priceLevels</code>, <code>minRating</code>, <code>strictTypeFiltering</code>), place details, directions, distance matrix, timezone, elevation, weather, air quality, static maps, batch geocode, and the composite tools explore-area, plan-route, compare-places, search-along-route, and local-rank-tracker. Tools are declared read-only, non-destructive, idempotent, and open-world via MCP annotations. The server ships the <strong>eatspot-discovery</strong> agent skill for budget-, quality-, category-, and schedule-validated venue search, and installs itself plus its skills into supported CLI agents (pi, OpenClaw, Codex, Antigravity, Claude) with one command.
|
|
26
|
+
</p>
|
|
27
27
|
|
|
28
|
-
|
|
28
|
+
<p align="center">
|
|
29
|
+
<a href="#feature-highlights">Feature Highlights</a> |
|
|
30
|
+
<a href="#quick-start">Quick Start</a> |
|
|
31
|
+
<a href="#requirements">Requirements</a> |
|
|
32
|
+
<a href="#users-guide">User's Guide</a> |
|
|
33
|
+
<a href="#acknowledgments">Acknowledgments</a>
|
|
34
|
+
</p>
|
|
29
35
|
|
|
30
|
-
|
|
36
|
+
<p align="center">
|
|
37
|
+
🚧 <strong>STAGE:</strong> PRE-ALPHA 📝 — Proof-of-Concept (PoC), Work in Progress 🏗️ 🚧
|
|
38
|
+
<br>
|
|
39
|
+
⚠️ <strong>IMPORTANT NOTICE</strong>: Created with <a href="https://www.npmjs.com/package/pi-usereq"><strong>PI-useReq/pi-usereq</strong></a> 🤖✨ ⚠️
|
|
40
|
+
</p>
|
|
31
41
|
|
|
32
42
|
# Feature Highlights
|
|
33
43
|
|
|
@@ -58,7 +68,7 @@ mcp-google-api api-key "AIza..."
|
|
|
58
68
|
mcp-google-api doctor # local self-check: Node, package, key, settings (no network)
|
|
59
69
|
```
|
|
60
70
|
|
|
61
|
-
**3. Run** — register the server into your CLI agents (supported: `pi`, `openclaw`, `codex`, `antigravity`, `claude`), then start it:
|
|
71
|
+
**3. Run** — register the server into your CLI agents (supported: `pi`, `openclaw`, `codex`, `antigravity`, `claude`, `copilot`), then start it:
|
|
62
72
|
|
|
63
73
|
```bash
|
|
64
74
|
mcp-google-api enable pi
|
|
@@ -129,10 +139,11 @@ The `--host` and `--port` flags override the persisted settings for a single `st
|
|
|
129
139
|
| codex | `~/.codex/config.toml` (`mcp_servers` table) | `~/.codex/skills` |
|
|
130
140
|
| antigravity | `~/.gemini/settings.json` | `~/.gemini/config/skills` |
|
|
131
141
|
| claude | `~/.claude.json` | `~/.claude/skills` |
|
|
142
|
+
| copilot | `~/.copilot/mcp.json` | `~/.copilot/skills` |
|
|
132
143
|
|
|
133
144
|
- **pi**: after installing, run `/reload` in the session if the configuration was changed externally; `/mcp` inspects status, tools, and connection errors.
|
|
134
145
|
- **OpenClaw**: reload the gateway or restart the agent session so the new server gets connected.
|
|
135
|
-
- `mcp-google-api show` prints the CLI Configuration table (all
|
|
146
|
+
- `mcp-google-api show` prints the CLI Configuration table (all six agents) and the Installation Status table (server + each skill per enabled CLI with OK / MISSING / STALE).
|
|
136
147
|
- `mcp-google-api install --debug-skills` additionally appends each skill's packaged debug overlay to the installed `SKILL.md`; plain installs and `api-key`/`--upgrade` refreshes never append it, and `show` reports OK in both modes.
|
|
137
148
|
|
|
138
149
|
## Running the server
|
|
@@ -149,6 +160,17 @@ mcp-google-api run # alias of start
|
|
|
149
160
|
- stdio mode refuses to start without a configured key and exits 1 with a stderr error inviting `mcp-google-api api-key <key>`; HTTP mode starts anyway and logs a warning (per-request header keys remain usable).
|
|
150
161
|
- The automatic update check runs at startup (default on): a newer npm version is reported on stderr only with an upgrade command; it never blocks startup.
|
|
151
162
|
|
|
163
|
+
### stdio vs Streamable HTTP
|
|
164
|
+
|
|
165
|
+
| | stdio | Streamable HTTP |
|
|
166
|
+
|---|---|---|
|
|
167
|
+
| Launch | `mcp-google-api start --stdio` (what `install` registers in MCP-client configs) | `mcp-google-api start` or `run`, with optional `--host`/`--port` |
|
|
168
|
+
| Channel | JSON-RPC 2.0 frames over stdin/stdout; stdout carries only protocol traffic, diagnostics go to stderr | HTTP POST/GET/DELETE on `http://<host>:<port>/mcp`; GET upgrades to SSE for server-to-client notifications |
|
|
169
|
+
| API key | resolved once at startup from the persisted `apiKey` setting; startup fails without one | per-request `X-Google-Maps-API-Key` or `Authorization: Bearer` header, then the session key, then the configured setting; startup only warns without one |
|
|
170
|
+
| Typical use | locally registered MCP clients (pi, OpenClaw, Codex, Antigravity, Claude) launched by `install` | remote or multi-client access to one shared server, each client isolated by its `mcp-session-id` |
|
|
171
|
+
|
|
172
|
+
Use **stdio** when a local MCP client launches the server from its own configuration; use **Streamable HTTP** when several clients, local or remote, share one server instance. Both transports expose the same 18 tools and the same per-session/per-request key isolation semantics.
|
|
173
|
+
|
|
152
174
|
## Per-request API keys
|
|
153
175
|
|
|
154
176
|
On the HTTP transport each request may supply its own key with top priority: the `X-Google-Maps-API-Key` header, or an `Authorization: Bearer <key>` header. Each session (`mcp-session-id`) keeps its session key; the configured `apiKey` setting is the fallback. This lets concurrent clients use isolated credentials against one server.
|
|
@@ -167,7 +189,7 @@ mcp-google-api doctor --live --apikey "AIza..." # override the key for the probe
|
|
|
167
189
|
## One-shot CLI tools
|
|
168
190
|
|
|
169
191
|
```bash
|
|
170
|
-
mcp-google-api exec
|
|
192
|
+
mcp-google-api exec maps_geocode '{"address":"Tokyo Tower"}' # run one tool by its canonical maps_ name
|
|
171
193
|
mcp-google-api batch-geocode -i addresses.txt -o results.json # geocode one address per line
|
|
172
194
|
cat addresses.txt | mcp-google-api batch-geocode -i - # from stdin
|
|
173
195
|
```
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* @file mcp-google-api.mjs
|
|
4
|
+
* @brief Installed distribution bin launcher executing the mcp-google-api Node.js CLI (PRJ-020).
|
|
5
|
+
* @details Mirrors `scripts/mcp-google-api.sh` for the installed package: resolves the
|
|
6
|
+
* real package root from this script's own location (realpath-safe against npm's
|
|
7
|
+
* symlinked global `bin/` links and renamed launchers), verifies the packaged
|
|
8
|
+
* `dist/cli.js` entry exists, and either forwards every argument unchanged to that
|
|
9
|
+
* Node.js entry with inherited stdio, propagating its exit code (PRJ-020, PRJ-019
|
|
10
|
+
* semantics), or prints exactly one JSON build-remediation diagnostic on stderr
|
|
11
|
+
* naming the package root and the build/refresh commands, exiting non-zero
|
|
12
|
+
* (PRJ-021; remediation guidance in the REQ-094 family). No implicit install or
|
|
13
|
+
* build steps are ever executed (PRJ-019). A plain Node.js ESM script is used
|
|
14
|
+
* instead of pointing the npm `bin` field directly at `dist/cli.js` because a built
|
|
15
|
+
* artifact cannot detect its own absence: the launcher must stay runnable on stale
|
|
16
|
+
* or unbuilt distributions to deliver the remediation path. On Windows, npm wraps
|
|
17
|
+
* this file in a `.cmd` shim that invokes `node`, so the shebang is informational.
|
|
18
|
+
* @satisfies PRJ-016, PRJ-020, PRJ-021
|
|
19
|
+
* @note stdout is reserved for the launched CLI; this launcher writes only to
|
|
20
|
+
* stderr, and only on the missing-artifact remediation path (PRJ-021).
|
|
21
|
+
* @warning The remediation diagnostic is emitted by this launcher, never by
|
|
22
|
+
* `dist/cli.js`: a missing artifact bypasses every CLI-side guard (REQ-094 covers
|
|
23
|
+
* dispatch from an existing artifact; PRJ-021 covers the artifact-missing case).
|
|
24
|
+
*/
|
|
25
|
+
import { spawnSync } from "node:child_process";
|
|
26
|
+
import { existsSync, realpathSync } from "node:fs";
|
|
27
|
+
import { dirname, join } from "node:path";
|
|
28
|
+
import { fileURLToPath } from "node:url";
|
|
29
|
+
|
|
30
|
+
const launcherPath = realpathSync(fileURLToPath(import.meta.url));
|
|
31
|
+
const packageRoot = dirname(dirname(launcherPath));
|
|
32
|
+
const cliEntry = join(packageRoot, "dist", "cli.js");
|
|
33
|
+
|
|
34
|
+
if (!existsSync(cliEntry)) {
|
|
35
|
+
process.stderr.write(
|
|
36
|
+
JSON.stringify(
|
|
37
|
+
{
|
|
38
|
+
error: "dist/cli.js missing",
|
|
39
|
+
packageRoot,
|
|
40
|
+
remediation:
|
|
41
|
+
"build first: npm ci && npm run build (source checkout) or refresh the global install: npm install -g mcp-google-api@latest",
|
|
42
|
+
},
|
|
43
|
+
null,
|
|
44
|
+
2,
|
|
45
|
+
) + "\n",
|
|
46
|
+
);
|
|
47
|
+
process.exit(1);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
const child = spawnSync(process.execPath, [cliEntry, ...process.argv.slice(2)], {
|
|
51
|
+
stdio: "inherit",
|
|
52
|
+
});
|
|
53
|
+
process.exit(child.status ?? 1);
|
package/dist/cli.d.ts
CHANGED
|
@@ -61,7 +61,7 @@ declare function startServer(port: number, apiKey?: string, host?: string): Prom
|
|
|
61
61
|
type ShutdownExitHook = (code: number) => void;
|
|
62
62
|
declare function createShutdownHandler(servers: readonly BaseMcpServer[], exitHook?: ShutdownExitHook): (signal: string) => Promise<void>;
|
|
63
63
|
declare function installShutdownHandlers(servers: readonly BaseMcpServer[]): void;
|
|
64
|
-
declare const EXEC_TOOLS: readonly ["
|
|
64
|
+
declare const EXEC_TOOLS: readonly ["maps_geocode", "maps_reverse_geocode", "maps_search_nearby", "maps_search_places", "maps_place_details", "maps_directions", "maps_distance_matrix", "maps_elevation", "maps_timezone", "maps_weather", "maps_explore_area", "maps_plan_route", "maps_compare_places", "maps_air_quality", "maps_static_map", "maps_batch_geocode", "maps_search_along_route", "maps_local_rank_tracker"];
|
|
65
65
|
interface ExecOutput {
|
|
66
66
|
write(chunk: string): unknown;
|
|
67
67
|
}
|