@theyahia/megaplan-mcp 3.0.0 → 4.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/LICENSE +21 -21
- package/README.md +119 -157
- package/dist/client.d.ts +3 -13
- package/dist/client.js +224 -82
- package/dist/client.js.map +1 -1
- package/dist/format.d.ts +12 -0
- package/dist/format.js +148 -0
- package/dist/format.js.map +1 -0
- package/dist/http.d.ts +3 -0
- package/dist/http.js +152 -0
- package/dist/http.js.map +1 -0
- package/dist/index.d.ts +2 -13
- package/dist/index.js +97 -23
- package/dist/index.js.map +1 -1
- package/dist/meta.d.ts +2 -0
- package/dist/meta.js +5 -0
- package/dist/meta.js.map +1 -0
- package/dist/prompts.d.ts +7 -0
- package/dist/prompts.js +22 -0
- package/dist/prompts.js.map +1 -0
- package/dist/query.d.ts +32 -0
- package/dist/query.js +61 -0
- package/dist/query.js.map +1 -0
- package/dist/tools/comments.d.ts +9 -7
- package/dist/tools/comments.js +18 -21
- package/dist/tools/comments.js.map +1 -1
- package/dist/tools/contractors.d.ts +35 -0
- package/dist/tools/contractors.js +39 -0
- package/dist/tools/contractors.js.map +1 -0
- package/dist/tools/deals.d.ts +53 -8
- package/dist/tools/deals.js +71 -23
- package/dist/tools/deals.js.map +1 -1
- package/dist/tools/employees.d.ts +7 -5
- package/dist/tools/employees.js +16 -12
- package/dist/tools/employees.js.map +1 -1
- package/dist/tools/me.d.ts +9 -0
- package/dist/tools/me.js +26 -0
- package/dist/tools/me.js.map +1 -0
- package/dist/tools/programs.d.ts +26 -0
- package/dist/tools/programs.js +25 -0
- package/dist/tools/programs.js.map +1 -0
- package/dist/tools/projects.d.ts +21 -8
- package/dist/tools/projects.js +26 -13
- package/dist/tools/projects.js.map +1 -1
- package/dist/tools/tasks.d.ts +49 -10
- package/dist/tools/tasks.js +62 -20
- package/dist/tools/tasks.js.map +1 -1
- package/dist/types.d.ts +44 -53
- package/dist/types.js +4 -0
- package/dist/types.js.map +1 -1
- package/package.json +69 -63
- package/dist/client.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/server.d.ts +0 -9
- package/dist/server.d.ts.map +0 -1
- package/dist/server.js +0 -73
- package/dist/server.js.map +0 -1
- package/dist/tools/comments.d.ts.map +0 -1
- package/dist/tools/deals.d.ts.map +0 -1
- package/dist/tools/employees.d.ts.map +0 -1
- package/dist/tools/projects.d.ts.map +0 -1
- package/dist/tools/tasks.d.ts.map +0 -1
- package/dist/types.d.ts.map +0 -1
- package/smithery.yaml +0 -33
package/LICENSE
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2026 theYahia
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 theYahia
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,68 +1,64 @@
|
|
|
1
1
|
# @theyahia/megaplan-mcp
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
MCP server for **Megaplan** project management. Tasks, deals, projects,
|
|
4
|
+
employees, clients, and comments via Megaplan API v3.
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
> **v4.0 is a breaking release** (and the first npm release of this overhaul —
|
|
7
|
+
> it supersedes the older 8-tool `3.0.0`). Request/response shapes changed to
|
|
8
|
+
> match the real v3 API, and `--http` now requires an auth token. See
|
|
9
|
+
> [CHANGELOG.md](./CHANGELOG.md) and [Migrating from older versions](#migrating-from-older-versions).
|
|
8
10
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
### Migrating from v1.x
|
|
12
|
-
|
|
13
|
-
If you used v1.x, the v2.0.0 release introduces a few breaking changes:
|
|
14
|
-
|
|
15
|
-
- **HTTP transport env var renamed:** `PORT=3000` → `HTTP_PORT=3000`.
|
|
16
|
-
- **Removed separate `--http` codepath:** v1 had a hand-rolled `http.ts` triggered by `--http`. v2 uses `@theyahia/mcp-core`'s `runServer` which auto-routes via `--http` flag OR `HTTP_PORT` env. Same CLI flag, different implementation (now with session management, `/health` endpoint, CORS, graceful shutdown).
|
|
17
|
-
- **Internal client:** rewritten on `@theyahia/mcp-core`'s `BaseHttpClient` with a custom `MegaplanAuthStrategy` (Password grant flow). The exported `megaplanGet`/`megaplanPost` API is unchanged.
|
|
18
|
-
- **Tool errors:** now returned as MCP-spec `CallToolResult` with `isError: true` (via `withErrorHandling`).
|
|
19
|
-
|
|
20
|
-
Tool names, arguments, return formats, MCP prompts (`my-tasks-today`, `create-deal-wizard`), and `MEGAPLAN_*` env vars are unchanged.
|
|
21
|
-
|
|
22
|
-
---
|
|
23
|
-
|
|
24
|
-
## Tools (8) + Prompts (2)
|
|
25
|
-
|
|
26
|
-
### Tasks
|
|
11
|
+
## Tools (18)
|
|
27
12
|
|
|
28
13
|
| Tool | Description |
|
|
29
|
-
|
|
30
|
-
| `get_tasks` | List tasks
|
|
31
|
-
| `
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
|
36
|
-
|
|
37
|
-
| `
|
|
38
|
-
| `
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
|
43
|
-
|
|
44
|
-
| `
|
|
45
|
-
| `
|
|
46
|
-
|
|
47
|
-
|
|
14
|
+
|------|------------|
|
|
15
|
+
| `get_tasks` | List tasks; filter by status code(s), responsible, search |
|
|
16
|
+
| `get_task` | Get one task by ID |
|
|
17
|
+
| `create_task` | Create a task (name, description, responsible, deadline) |
|
|
18
|
+
| `update_task` | Update a task (name, description, responsible, deadline, status) |
|
|
19
|
+
| `get_deals` | List deals; filter by status code(s), responsible, search |
|
|
20
|
+
| `get_deal` | Get one deal by ID |
|
|
21
|
+
| `create_deal` | Create a deal (requires a program/pipeline ID) |
|
|
22
|
+
| `update_deal` | Update a deal (name, responsible, amount, description, status) |
|
|
23
|
+
| `get_projects` | List projects; filter by status code(s), search |
|
|
24
|
+
| `get_project` | Get one project by ID |
|
|
25
|
+
| `get_employees` | List employees; search + department filter |
|
|
26
|
+
| `get_deal_programs` | List deal programs (pipelines) — find the `program_id` for `create_deal` |
|
|
27
|
+
| `get_deal_program` | Get one deal program by ID |
|
|
28
|
+
| `list_clients` | List clients (contractors): people (`human`) or orgs (`company`) |
|
|
29
|
+
| `get_client` | Get one client by type + ID |
|
|
30
|
+
| `get_current_user` | Authenticated user's employee record (**experimental**) |
|
|
31
|
+
| `get_comments` | List comments on a task/deal/project |
|
|
32
|
+
| `create_comment` | Add a comment to a task/deal/project |
|
|
33
|
+
|
|
34
|
+
All list/get tools return a **compact summary** by default; pass `raw: true` for
|
|
35
|
+
the unmodified API JSON. Lists are cursor-paginated: pass the returned
|
|
36
|
+
`nextPageAfter` as `page_after` to get the next page.
|
|
37
|
+
|
|
38
|
+
## Skills (Prompts)
|
|
39
|
+
|
|
40
|
+
| Skill | Description |
|
|
41
|
+
|-------|------------|
|
|
42
|
+
| `my-tasks-today` | "Мои задачи на сегодня" — your tasks (scoped via `get_current_user`) |
|
|
43
|
+
| `create-deal-wizard` | "Создай сделку" — guided deal creation (lists pipelines first) |
|
|
44
|
+
|
|
45
|
+
## Setup
|
|
46
|
+
|
|
47
|
+
### Option A: Access Token
|
|
48
48
|
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
| `get_comments` | List comments on a task / deal / project. |
|
|
52
|
-
| `create_comment` | Add a comment to a task / deal / project. |
|
|
53
|
-
|
|
54
|
-
### MCP Prompts
|
|
49
|
+
1. In Megaplan, go to **Settings → Integration → API**.
|
|
50
|
+
2. Generate an access token, and set it as `MEGAPLAN_TOKEN`.
|
|
55
51
|
|
|
56
|
-
|
|
57
|
-
|--------|-------------|
|
|
58
|
-
| `my-tasks-today` | "Мои задачи на сегодня" — fetches your active tasks sorted by urgency, marks overdue. |
|
|
59
|
-
| `create-deal-wizard` | "Создай сделку" — guided deal creation wizard via conversation. |
|
|
52
|
+
### Option B: Login + Password
|
|
60
53
|
|
|
61
|
-
|
|
54
|
+
Set `MEGAPLAN_LOGIN` (email) + `MEGAPLAN_PASSWORD`. The server exchanges them for
|
|
55
|
+
an access token (cached in memory, re-authenticated on expiry).
|
|
62
56
|
|
|
63
|
-
|
|
57
|
+
`MEGAPLAN_DOMAIN` is your account host. A bare subdomain like `yourcompany` is
|
|
58
|
+
expanded to `yourcompany.megaplan.ru`; a full host (`crm.example.com`) is used
|
|
59
|
+
as-is.
|
|
64
60
|
|
|
65
|
-
|
|
61
|
+
## Usage with Claude Desktop
|
|
66
62
|
|
|
67
63
|
```json
|
|
68
64
|
{
|
|
@@ -72,135 +68,101 @@ Tool names, arguments, return formats, MCP prompts (`my-tasks-today`, `create-de
|
|
|
72
68
|
"args": ["-y", "@theyahia/megaplan-mcp"],
|
|
73
69
|
"env": {
|
|
74
70
|
"MEGAPLAN_DOMAIN": "yourcompany",
|
|
75
|
-
"MEGAPLAN_TOKEN": "
|
|
71
|
+
"MEGAPLAN_TOKEN": "your-access-token"
|
|
76
72
|
}
|
|
77
73
|
}
|
|
78
74
|
}
|
|
79
75
|
}
|
|
80
76
|
```
|
|
81
77
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
```json
|
|
85
|
-
{
|
|
86
|
-
"mcpServers": {
|
|
87
|
-
"megaplan": {
|
|
88
|
-
"command": "npx",
|
|
89
|
-
"args": ["-y", "@theyahia/megaplan-mcp"],
|
|
90
|
-
"env": {
|
|
91
|
-
"MEGAPLAN_DOMAIN": "yourcompany",
|
|
92
|
-
"MEGAPLAN_LOGIN": "user@example.com",
|
|
93
|
-
"MEGAPLAN_PASSWORD": "your_password"
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
```
|
|
78
|
+
Or with login/password — replace `MEGAPLAN_TOKEN` with `MEGAPLAN_LOGIN` +
|
|
79
|
+
`MEGAPLAN_PASSWORD`.
|
|
99
80
|
|
|
100
|
-
|
|
81
|
+
## Finding IDs
|
|
101
82
|
|
|
102
|
-
|
|
83
|
+
Several tools take IDs. Here's how to discover them via the server itself:
|
|
103
84
|
|
|
104
|
-
|
|
85
|
+
- **`responsible_id`, `filter_responsible_id`** → `get_employees` (each item has an `id`).
|
|
86
|
+
- **`filter_department_id`** → IDs appear on employees' `department` (or your Megaplan UI).
|
|
87
|
+
- **`program_id`** (required by `create_deal`) → `get_deal_programs`.
|
|
88
|
+
- **`contact_id`** (for `create_deal`) → `list_clients` with `type: "human"` or `"company"`; pass the matching `contact_type`.
|
|
89
|
+
- **status codes** (`filter_status`) are account-specific enum codes (e.g. `filter_any`), not display names. Find them in your Megaplan UI / account API schema.
|
|
105
90
|
|
|
106
|
-
|
|
91
|
+
## Streamable HTTP transport
|
|
107
92
|
|
|
108
|
-
|
|
93
|
+
For remote/cloud deployments, run with `--http`. **Auth is mandatory** — the
|
|
94
|
+
server holds your Megaplan credentials, so it refuses to start without
|
|
95
|
+
`MCP_HTTP_TOKEN` and binds to loopback by default.
|
|
109
96
|
|
|
110
97
|
```bash
|
|
111
|
-
HTTP_PORT=3000 \
|
|
112
98
|
MEGAPLAN_DOMAIN=yourcompany \
|
|
113
|
-
MEGAPLAN_TOKEN=
|
|
114
|
-
|
|
115
|
-
|
|
99
|
+
MEGAPLAN_TOKEN=xxx \
|
|
100
|
+
MCP_HTTP_TOKEN=$(openssl rand -hex 32) \
|
|
101
|
+
npx @theyahia/megaplan-mcp --http
|
|
102
|
+
# → http://127.0.0.1:3000/mcp (send: Authorization: Bearer $MCP_HTTP_TOKEN)
|
|
103
|
+
# Health: http://127.0.0.1:3000/health
|
|
116
104
|
```
|
|
117
105
|
|
|
118
|
-
|
|
119
|
-
-
|
|
120
|
-
|
|
121
|
-
- `DELETE /mcp` — session termination
|
|
122
|
-
- `GET /health` — `{ status: "ok", version, tools, uptime, memory_mb }`
|
|
123
|
-
|
|
124
|
-
---
|
|
106
|
+
To expose beyond loopback, set `HOST=0.0.0.0` **and** add the public host:port to
|
|
107
|
+
`MCP_HTTP_ALLOWED_HOSTS` (DNS-rebinding protection is on). Only do this behind
|
|
108
|
+
your own network controls.
|
|
125
109
|
|
|
126
110
|
## Environment Variables
|
|
127
111
|
|
|
128
112
|
| Variable | Required | Description |
|
|
129
113
|
|----------|----------|-------------|
|
|
130
|
-
| `MEGAPLAN_DOMAIN` |
|
|
131
|
-
| `MEGAPLAN_TOKEN` |
|
|
132
|
-
| `MEGAPLAN_LOGIN` |
|
|
133
|
-
| `MEGAPLAN_PASSWORD` |
|
|
134
|
-
| `
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
##
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
> Use the `my-tasks-today` MCP prompt to get a daily standup view.
|
|
170
|
-
|
|
171
|
-
---
|
|
114
|
+
| `MEGAPLAN_DOMAIN` | Yes | Account host (`yourcompany` → `yourcompany.megaplan.ru`, or a full host) |
|
|
115
|
+
| `MEGAPLAN_TOKEN` | One of | Bearer access token |
|
|
116
|
+
| `MEGAPLAN_LOGIN` | One of | Login email (if no token) |
|
|
117
|
+
| `MEGAPLAN_PASSWORD` | One of | Password (if no token) |
|
|
118
|
+
| `MEGAPLAN_DEBUG` | No | `1` to log full upstream error bodies |
|
|
119
|
+
| `PORT` | No | HTTP port for `--http` mode (default: 3000) |
|
|
120
|
+
| `MCP_HTTP_TOKEN` | `--http` | Bearer token required to call `/mcp` (server refuses to start without it) |
|
|
121
|
+
| `HOST` | No | Bind address for `--http` (default `127.0.0.1`) |
|
|
122
|
+
| `MCP_HTTP_ALLOWED_HOSTS` | No | Comma-separated allowed `Host` values (default loopback:port) |
|
|
123
|
+
| `MCP_HTTP_BODY_LIMIT` | No | Max request body size (default `1mb`) |
|
|
124
|
+
| `MCP_HTTP_MAX_SESSIONS` | No | Max concurrent sessions (default `100`) |
|
|
125
|
+
| `MCP_HTTP_SESSION_TTL_MS` | No | Idle session eviction TTL (default 30 min) |
|
|
126
|
+
|
|
127
|
+
## Migrating from older versions
|
|
128
|
+
|
|
129
|
+
Applies to the previously published 8-tool builds (`1.x`–`3.0.0`):
|
|
130
|
+
|
|
131
|
+
- `get_*` list tools: `offset` → `page_after` (cursor); `filter_status` now takes
|
|
132
|
+
status **code(s)**, not names like `active`.
|
|
133
|
+
- Output is a compact summary by default — pass `raw: true` for the old raw JSON.
|
|
134
|
+
- `create_comment`: the text field is now `content` (was `text`).
|
|
135
|
+
- `--http`: set `MCP_HTTP_TOKEN`; the default bind is now `127.0.0.1`.
|
|
136
|
+
|
|
137
|
+
## Verification status
|
|
138
|
+
|
|
139
|
+
Most behaviour is confirmed against the official v3 RAML and real v3 client
|
|
140
|
+
libraries. A few items are best-effort from docs and marked `TODO(live-verify)`
|
|
141
|
+
in the source (and `experimental` here), pending a test against a live account:
|
|
142
|
+
auth body encoding, the free-text search param name, the `get_current_user`
|
|
143
|
+
endpoint, and the task/deal status-change field shape. Errors are surfaced
|
|
144
|
+
clearly (set `MEGAPLAN_DEBUG=1` for full detail) so any mismatch is diagnosable.
|
|
145
|
+
|
|
146
|
+
## Referral
|
|
147
|
+
|
|
148
|
+
Get **20-50% recurring** commission by referring Megaplan:
|
|
149
|
+
|
|
150
|
+
- [Megaplan Partner Program](https://megaplan.ru/partners/)
|
|
151
|
+
- Sign up as a partner, get your referral link.
|
|
152
|
+
- Every client you bring = recurring revenue share.
|
|
172
153
|
|
|
173
154
|
## Development
|
|
174
155
|
|
|
175
156
|
```bash
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
```
|
|
185
|
-
servers/megaplan/
|
|
186
|
-
├── src/
|
|
187
|
-
│ ├── index.ts — bin entry, runServer
|
|
188
|
-
│ ├── server.ts — createServer factory + 8 tools + 2 prompts
|
|
189
|
-
│ ├── client.ts — BaseHttpClient + MegaplanAuthStrategy (token OR Password grant)
|
|
190
|
-
│ ├── types.ts — TypeScript types
|
|
191
|
-
│ └── tools/
|
|
192
|
-
│ ├── comments.ts
|
|
193
|
-
│ ├── deals.ts
|
|
194
|
-
│ ├── employees.ts
|
|
195
|
-
│ ├── projects.ts
|
|
196
|
-
│ └── tasks.ts
|
|
197
|
-
└── tests/
|
|
198
|
-
├── client.test.ts — token + Password grant + 401 re-auth + body
|
|
199
|
-
└── server.test.ts — createServer factory smoke
|
|
157
|
+
npm install
|
|
158
|
+
npm run build # tsc -> dist/
|
|
159
|
+
npm run typecheck # tsc --noEmit (src + tests)
|
|
160
|
+
npm run lint # eslint
|
|
161
|
+
npm test # vitest
|
|
162
|
+
npm run dev # stdio mode with tsx
|
|
163
|
+
npm run start:http # HTTP mode (needs MCP_HTTP_TOKEN)
|
|
200
164
|
```
|
|
201
165
|
|
|
202
|
-
---
|
|
203
|
-
|
|
204
166
|
## License
|
|
205
167
|
|
|
206
|
-
MIT
|
|
168
|
+
MIT
|
package/dist/client.d.ts
CHANGED
|
@@ -1,14 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
* Custom auth that supports BOTH:
|
|
5
|
-
* 1. Direct token via MEGAPLAN_TOKEN env var (preferred)
|
|
6
|
-
* 2. Password grant via MEGAPLAN_LOGIN + MEGAPLAN_PASSWORD (with token caching)
|
|
7
|
-
*
|
|
8
|
-
* Wraps @theyahia/mcp-core's BaseHttpClient. Re-exports megaplanGet/megaplanPost
|
|
9
|
-
* as functional API so tools/* keep their signatures unchanged.
|
|
10
|
-
*/
|
|
11
|
-
export declare function resetClient(): void;
|
|
12
|
-
export declare function megaplanGet(path: string, params?: Record<string, string>): Promise<unknown>;
|
|
1
|
+
/** Test helper: reset cached auth state between cases. */
|
|
2
|
+
export declare function __resetAuth(): void;
|
|
3
|
+
export declare function megaplanGet(path: string, params?: Record<string, unknown>): Promise<unknown>;
|
|
13
4
|
export declare function megaplanPost(path: string, body: unknown): Promise<unknown>;
|
|
14
|
-
//# sourceMappingURL=client.d.ts.map
|