@awesomate/hosting-mcp 0.20.0 → 0.20.1

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/dist/index.js CHANGED
@@ -39891,7 +39891,11 @@ async function hubRequest(config3, method, path, jsonBody, opts = {}) {
39891
39891
  body = text;
39892
39892
  }
39893
39893
  if (!res.ok) {
39894
- const serverMsg = body && typeof body === "object" && "error" in body && typeof body.error === "string" ? body.error : `Request failed (${res.status})`;
39894
+ const asObj = body && typeof body === "object" ? body : null;
39895
+ const errField = typeof asObj?.error === "string" ? asObj.error : null;
39896
+ const msgField = typeof asObj?.message === "string" && asObj.message.trim() ? asObj.message.trim() : null;
39897
+ const looksLikeCode = errField !== null && /^[a-z0-9_]+$/.test(errField);
39898
+ const serverMsg = msgField ? looksLikeCode ? `${msgField} (${errField})` : msgField : errField ?? `Request failed (${res.status})`;
39895
39899
  const code = body && typeof body === "object" && "code" in body && typeof body.code === "string" ? body.code : null;
39896
39900
  let hint = "";
39897
39901
  if (res.status === 401) {
@@ -41584,7 +41588,7 @@ server.registerTool(
41584
41588
  server.registerTool(
41585
41589
  "awesomate_knowledge_ask",
41586
41590
  {
41587
- description: `Ask the account's knowledge base a question and get the VERIFIED answer with numbered sources (title, locator, url) \u2014 the test surface for 'is my content in there and answering well'. Read status: ok \u2192 present answer + sources. no_results / failed_validation (not_in_verified_content:true) \u2192 the verified content has no answer: relay that honestly (use configured_fallback), never fill the gap from memory \u2014 an honest "it doesn't know" is the feature working. error (platform_error:true) \u2192 the platform itself failed (model/API/infra): NOT a content gap \u2014 never tell the user their content lacks the answer; retry once, then awesomate_support. Counts against the monthly answers quota.`,
41591
+ description: `Ask the account's knowledge base a question and get the VERIFIED answer with numbered sources (title, locator, url) \u2014 the test surface for 'is my content in there and answering well'. Read BOTH status and grounded. grounded:true \u2192 present the answer with its numbered sources. grounded:false (status ok but ZERO sources) \u2192 the agent answered from MODEL MEMORY, not their content: say their content does not cover it, never present it as an answer from their knowledge base, never build on it. The default workspace agent is not strict-grounded, so this is common \u2014 anything customer-facing should use a purpose-built agent (awesomate_knowledge_agents) with strict grounding. no_results / failed_validation (not_in_verified_content:true) \u2192 the verified content has no answer: relay that honestly (use configured_fallback), never fill the gap from memory \u2014 an honest "it doesn't know" is the feature working. error (platform_error:true) \u2192 the platform itself failed (model/API/infra): NOT a content gap \u2014 never tell the user their content lacks the answer; retry once, then awesomate_support. Counts against the monthly answers quota.`,
41588
41592
  inputSchema: {
41589
41593
  question: external_exports.string().min(1).max(2e3),
41590
41594
  session: external_exports.string().max(128).optional().describe("Stable id to keep follow-up questions in one conversation thread"),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@awesomate/hosting-mcp",
3
- "version": "0.20.0",
3
+ "version": "0.20.1",
4
4
  "description": "Awesomate MCP server — lets Claude manage your Awesomate WordPress hosting, plan, limits, n8n automations, and build Node/static apps + databases",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",
@@ -1,5 +1,12 @@
1
1
  {
2
2
  "versions": [
3
+ {
4
+ "version": "0.20.1",
5
+ "highlights": [
6
+ "Claude now tells you clearly when an answer did NOT come from your content, instead of showing it like a verified one",
7
+ "Clearer error messages when something is not supported, instead of a generic failure"
8
+ ]
9
+ },
3
10
  {
4
11
  "version": "0.20.0",
5
12
  "highlights": [
@@ -124,13 +124,16 @@ enough to route through explicit REST calls the user has just approved.
124
124
 
125
125
  | Action | Endpoint |
126
126
  |---|---|
127
- | Status / provision / sources / jobs / agent / ask | `GET\|POST /api/knowledge/{status,provision,sources,jobs,agent,chat}` (tool equivalents) |
127
+ | Status / provision / sources / jobs / agent | `GET\|POST /api/knowledge/{status,provision,sources,jobs,agent}` (tool equivalents) |
128
+ | Ask the knowledge base | `POST /api/knowledge/chat` `{question, session?}` — **returns SSE (`text/event-stream`), NOT JSON.** `JSON.parse` of the body yields `null` and reading `.status` off it throws. Concatenate `event: answer` data lines; the single `event: meta` line carries the verdict `{status, sources, score}`. |
129
+ | Whole-library counts | `GET /api/knowledge/sources/summary` — a PATH. **`?action=summary` is NOT a thing:** it returns 200 with a plain source list, so `.total` is `undefined` and any count derived from it silently becomes 0 or NaN. |
128
130
  | Faceted search (what `awesomate_knowledge_search` calls) | `GET /api/knowledge/explore?q=…` + the same facet params. **Add `&include=media` to get `url`/`poster_url` on image/video hits** — without it you get titles with nothing to display. |
129
131
  | Business-data warehouse (what `awesomate_knowledge_data` calls) | `GET /api/knowledge/data/{metrics,datasets,datasets/:id,imports,imports/:id}` · `PATCH /api/knowledge/data/datasets/:id` · `POST /api/knowledge/data/imports/:id/:action` · `POST /api/knowledge/data/query` (read-only SQL) |
130
132
  | Agent builder (what `awesomate_knowledge_agents` calls) | `GET\|POST /api/knowledge/agents` · `GET\|PATCH\|DELETE /api/knowledge/agents/:agent_id` · `POST /api/knowledge/agents/:agent_id/{publish,suspend,resume}` |
131
133
  | **Test a DRAFT agent** (`action:'test'`) | `POST /api/knowledge/agents/:agent_id/chat` `{message, session_id?}`. There is **no** `/test` endpoint — guessing one returns 404. |
132
134
  | Entity layer probe (`available` false = not enabled yet, stop) | `GET /api/knowledge/entities` |
133
- | People list / detail | `GET /api/knowledge/people?status=named\|unknown\|hidden\|all` · `GET /api/knowledge/people/:id` |
135
+ | People list / detail | `GET /api/knowledge/people?status=named\|unknown\|hidden\|all` · `GET /api/knowledge/people/:id` — returns `{people, next_cursor}` and **no `counts` key**. |
136
+ | Entity COUNTS + availability | `GET /api/knowledge/entities` → `{available, counts: {...}}` — counts are nested under `counts`. Reading `people.counts?.x ?? 0` prints a confident row of zeros next to data that plainly exists. |
134
137
  | Name or hide/unhide a person (after approval) | `PATCH /api/knowledge/people/:id` `{display_name}` or `{status: "hidden"\|"unknown"}` |
135
138
  | Merge two people (after approval; source is hidden) | `POST /api/knowledge/people/:id/merge` `{into_person_id}` |
136
139
  | Alias suggestions / decision (identity = kind + alias_norm) | `GET /api/knowledge/entities/aliases?status=pending` · `POST /api/knowledge/entities/aliases/decision` `{kind, alias_norm, decision, entity_id? \| create_person?}` |
@@ -151,7 +154,10 @@ Learning one shape and applying it to the other is a guaranteed `400`:
151
154
  | `POST /api/knowledge/agents/:id/chat` — test a draft agent | `{message, session_id?, filters?}` |
152
155
 
153
156
  `question` vs `message`, `session` vs `session_id`. Both are strict objects, so
154
- sending both spellings to be safe fails too. Measured on a real first-time
157
+ sending both spellings to be safe fails too as does **camelCase**: `{message,
158
+ sessionId}` is a 400, and so is an extra `{draft: true}`. Going direct, use
159
+ snake_case and send nothing the schema does not name. (The MCP tool parameters
160
+ are camelCase — `sessionId`, `agentId` — because the tool translates for you.) Measured on a real first-time
155
161
  session (2026-09-01): fourteen `400`s and one `404` were spent rediscovering
156
162
  exactly this.
157
163