food402 1.0.2 → 1.0.3
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 +27 -0
- package/dist/postinstall.d.ts +2 -0
- package/dist/postinstall.js +29 -0
- package/package.json +2 -1
package/README.md
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
# Food402 MCP Server
|
|
2
2
|
|
|
3
|
+
[](https://www.npmjs.com/package/food402)
|
|
4
|
+
|
|
3
5
|
An MCP (Model Context Protocol) server that enables AI assistants to order food from TGO Yemek. Simply chat with your AI assistant to browse restaurants, build your order, and complete checkout.
|
|
4
6
|
|
|
5
7
|
## Installation
|
|
@@ -23,6 +25,31 @@ Add to your Claude Desktop config (`~/Library/Application Support/Claude/claude_
|
|
|
23
25
|
|
|
24
26
|
Replace `your-email@example.com` and `your-password` with your TGO Yemek credentials.
|
|
25
27
|
|
|
28
|
+
## Local Installation (Claude Code)
|
|
29
|
+
|
|
30
|
+
For project-specific installation with Claude Code:
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
npm install food402
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
This automatically adds `food402` to your `.mcp.json`. Open the file and update your credentials:
|
|
37
|
+
|
|
38
|
+
```json
|
|
39
|
+
{
|
|
40
|
+
"mcpServers": {
|
|
41
|
+
"food402": {
|
|
42
|
+
"command": "node",
|
|
43
|
+
"args": ["./node_modules/food402/dist/index.js"],
|
|
44
|
+
"env": {
|
|
45
|
+
"TGO_EMAIL": "your-email@example.com",
|
|
46
|
+
"TGO_PASSWORD": "your-password"
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
```
|
|
52
|
+
|
|
26
53
|
## Prerequisites
|
|
27
54
|
|
|
28
55
|
### Account Setup Required
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { readFileSync, writeFileSync, existsSync } from 'fs';
|
|
3
|
+
import { join } from 'path';
|
|
4
|
+
// Find project root (where npm install was run)
|
|
5
|
+
const projectRoot = process.env.INIT_CWD || process.cwd();
|
|
6
|
+
const mcpJsonPath = join(projectRoot, '.mcp.json');
|
|
7
|
+
const food402Config = {
|
|
8
|
+
command: "node",
|
|
9
|
+
args: ["./node_modules/food402/dist/index.js"],
|
|
10
|
+
env: {
|
|
11
|
+
TGO_EMAIL: "your-email@example.com",
|
|
12
|
+
TGO_PASSWORD: "your-password"
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
let config = { mcpServers: {} };
|
|
16
|
+
if (existsSync(mcpJsonPath)) {
|
|
17
|
+
try {
|
|
18
|
+
config = JSON.parse(readFileSync(mcpJsonPath, 'utf-8'));
|
|
19
|
+
if (!config.mcpServers)
|
|
20
|
+
config.mcpServers = {};
|
|
21
|
+
}
|
|
22
|
+
catch {
|
|
23
|
+
// Invalid JSON, start fresh
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
config.mcpServers.food402 = food402Config;
|
|
27
|
+
writeFileSync(mcpJsonPath, JSON.stringify(config, null, 2) + '\n');
|
|
28
|
+
console.log('✓ Added food402 to .mcp.json');
|
|
29
|
+
console.log('→ Update TGO_EMAIL and TGO_PASSWORD in .mcp.json with your credentials');
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "food402",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.3",
|
|
4
4
|
"description": "MCP server for ordering food from TGO Yemek",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
"scripts": {
|
|
13
13
|
"start": "tsx src/index.ts",
|
|
14
14
|
"build": "tsc",
|
|
15
|
+
"postinstall": "node dist/postinstall.js",
|
|
15
16
|
"prepublishOnly": "npm run build"
|
|
16
17
|
},
|
|
17
18
|
"keywords": [
|