Commit d27803e
🐛 fix: fix OpenClaw plugin API compatibility with EverMemOS v1
The plugin was not working out of the box with the current EverMemOS API.
Several request format mismatches caused 404, 405, 422, and fetch errors
when used with OpenClaw.
Fixes:
1. API version: /api/v0/ → /api/v1/
The plugin hardcoded /api/v0/ for both search and capture endpoints,
but EverMemOS serves its API under /api/v1/. All requests returned 404.
2. Search field name: group_ids (array) → group_id (string)
The plugin sent `group_ids: ["group-name"]` but the EverMemOS
/memories/search endpoint expects `group_id: "group-name"` (a plain
string). The array field was silently ignored, causing unscoped searches.
3. Capture role mapping: "tool" → "assistant"
OpenClaw agent conversations include messages with role "tool" (tool
call results). EverMemOS validates roles strictly and only accepts
"user" or "assistant", returning HTTP 422 for any other value. Tool
and system messages are now mapped to "assistant" since they are part
of the assistant's workflow.
4. Search memory_types: array → comma-separated string
The plugin sent memory_types as repeated query parameters
(memory_types=a&memory_types=b). However, EverMemOS collects query
params via dict(request.query_params) which flattens multi-value keys,
keeping only the last value. The _parse_memory_types() function already
supports comma-separated strings, so sending "a,b" works correctly.
5. README: fix example load.paths
Changed the example path from "/path/to/EverMemOS-OpenClaw-Plugin"
(wrong case, not a real path) to "~/.openclaw/extensions/evermemos-
openclaw-plugin" which is the standard OpenClaw extensions directory.
Note: OpenClaw resolves relative paths from the gateway process's
working directory (process.cwd()), not from ~/.openclaw/, so using ~/
or absolute paths is required.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent 0f49826 commit d27803e
File tree
3 files changed
+10
-9
lines changed- evermemos-openclaw-plugin
- src
3 files changed
+10
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
| 31 | + | |
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
16 | | - | |
17 | | - | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
42 | | - | |
43 | | - | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
44 | 45 | | |
45 | 46 | | |
46 | 47 | | |
| |||
58 | 59 | | |
59 | 60 | | |
60 | 61 | | |
61 | | - | |
62 | | - | |
| 62 | + | |
| 63 | + | |
63 | 64 | | |
64 | 65 | | |
65 | 66 | | |
0 commit comments