firebase-mcp 0.1.0 → 0.1.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.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "firebase-mcp",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"description": "MCP server that exposes Firebase Firestore to AI agents (Cursor, Claude Desktop, etc.)",
|
|
5
5
|
"main": "dist/cli/index.js",
|
|
6
6
|
"bin": {
|
|
@@ -24,6 +24,10 @@
|
|
|
24
24
|
"cursor",
|
|
25
25
|
"claude"
|
|
26
26
|
],
|
|
27
|
+
"repository": {
|
|
28
|
+
"type": "git",
|
|
29
|
+
"url": "https://github.com/s-h-u-h-a-r-i/firebase-mcp"
|
|
30
|
+
},
|
|
27
31
|
"author": "triston.c.0186@gmail.com",
|
|
28
32
|
"license": "MIT",
|
|
29
33
|
"packageManager": "pnpm@10.33.0",
|
|
@@ -35,14 +39,5 @@
|
|
|
35
39
|
"firebase-admin": "^13.7.0",
|
|
36
40
|
"micromatch": "^4.0.8",
|
|
37
41
|
"minimist": "^1.2.8"
|
|
38
|
-
},
|
|
39
|
-
"devDependencies": {
|
|
40
|
-
"@effect/language-service": "^0.84.3",
|
|
41
|
-
"@types/micromatch": "^4.0.10",
|
|
42
|
-
"@types/minimist": "^1.2.5",
|
|
43
|
-
"@types/node": "^25.5.2",
|
|
44
|
-
"ts-node": "^10.9.2",
|
|
45
|
-
"tsx": "^4.21.0",
|
|
46
|
-
"typescript": "^6.0.2"
|
|
47
42
|
}
|
|
48
43
|
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import admin from 'firebase-admin';
|
|
2
|
-
export declare const normalizeValue: (value: unknown) => unknown;
|
|
3
|
-
export declare const normalizeDocument: (doc: admin.firestore.QueryDocumentSnapshot | admin.firestore.DocumentSnapshot) => {
|
|
4
|
-
id: string;
|
|
5
|
-
path: string;
|
|
6
|
-
data: unknown;
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=normalize.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"normalize.d.ts","sourceRoot":"","sources":["../../../src/tools/firestore/normalize.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,gBAAgB,CAAC;AAEnC,eAAO,MAAM,cAAc,GAAI,OAAO,OAAO,KAAG,OAmB/C,CAAC;AAEF,eAAO,MAAM,iBAAiB,GAC5B,KAAK,KAAK,CAAC,SAAS,CAAC,qBAAqB,GAAG,KAAK,CAAC,SAAS,CAAC,gBAAgB;;;;CAK7E,CAAC"}
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.normalizeDocument = exports.normalizeValue = void 0;
|
|
7
|
-
const firebase_admin_1 = __importDefault(require("firebase-admin"));
|
|
8
|
-
const normalizeValue = (value) => {
|
|
9
|
-
if (value === null || value === undefined)
|
|
10
|
-
return value;
|
|
11
|
-
if (value instanceof firebase_admin_1.default.firestore.Timestamp) {
|
|
12
|
-
return value.toDate().toISOString();
|
|
13
|
-
}
|
|
14
|
-
if (value instanceof firebase_admin_1.default.firestore.GeoPoint) {
|
|
15
|
-
return { latitude: value.latitude, longitude: value.longitude };
|
|
16
|
-
}
|
|
17
|
-
if (value instanceof firebase_admin_1.default.firestore.DocumentReference)
|
|
18
|
-
return value.path;
|
|
19
|
-
if (Array.isArray(value))
|
|
20
|
-
return value.map(exports.normalizeValue);
|
|
21
|
-
if (typeof value === 'object') {
|
|
22
|
-
return Object.fromEntries(Object.entries(value).map(([k, v]) => [
|
|
23
|
-
k,
|
|
24
|
-
(0, exports.normalizeValue)(v),
|
|
25
|
-
]));
|
|
26
|
-
}
|
|
27
|
-
return value;
|
|
28
|
-
};
|
|
29
|
-
exports.normalizeValue = normalizeValue;
|
|
30
|
-
const normalizeDocument = (doc) => ({
|
|
31
|
-
id: doc.id,
|
|
32
|
-
path: doc.ref.path,
|
|
33
|
-
data: (0, exports.normalizeValue)(doc.data()),
|
|
34
|
-
});
|
|
35
|
-
exports.normalizeDocument = normalizeDocument;
|
|
36
|
-
//# sourceMappingURL=normalize.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"normalize.js","sourceRoot":"","sources":["../../../src/tools/firestore/normalize.ts"],"names":[],"mappings":";;;;;;AAAA,oEAAmC;AAE5B,MAAM,cAAc,GAAG,CAAC,KAAc,EAAW,EAAE;IACxD,IAAI,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS;QAAE,OAAO,KAAK,CAAC;IACxD,IAAI,KAAK,YAAY,wBAAK,CAAC,SAAS,CAAC,SAAS,EAAE,CAAC;QAC/C,OAAO,KAAK,CAAC,MAAM,EAAE,CAAC,WAAW,EAAE,CAAC;IACtC,CAAC;IACD,IAAI,KAAK,YAAY,wBAAK,CAAC,SAAS,CAAC,QAAQ,EAAE,CAAC;QAC9C,OAAO,EAAE,QAAQ,EAAE,KAAK,CAAC,QAAQ,EAAE,SAAS,EAAE,KAAK,CAAC,SAAS,EAAE,CAAC;IAClE,CAAC;IACD,IAAI,KAAK,YAAY,wBAAK,CAAC,SAAS,CAAC,iBAAiB;QAAE,OAAO,KAAK,CAAC,IAAI,CAAC;IAC1E,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC;QAAE,OAAO,KAAK,CAAC,GAAG,CAAC,sBAAc,CAAC,CAAC;IAC3D,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;QAC9B,OAAO,MAAM,CAAC,WAAW,CACvB,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAA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