@karmaniverous/jeeves-server-openclaw 0.1.0-0 → 0.1.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/dist/index.js +44 -17
- package/dist/skills/jeeves-server/SKILL.md +5 -1
- package/openclaw.plugin.json +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -23,7 +23,10 @@ function getPluginKey(api) {
|
|
|
23
23
|
}
|
|
24
24
|
/** Derive HMAC key from seed. */
|
|
25
25
|
function deriveKey(seed) {
|
|
26
|
-
return createHmac('sha256', seed)
|
|
26
|
+
return createHmac('sha256', seed)
|
|
27
|
+
.update('insider')
|
|
28
|
+
.digest('hex')
|
|
29
|
+
.substring(0, 32);
|
|
27
30
|
}
|
|
28
31
|
/** Append auth key query param to a URL. */
|
|
29
32
|
function withAuth(url, keySeed) {
|
|
@@ -265,20 +268,40 @@ async function generateServerMenu(apiUrl) {
|
|
|
265
268
|
`jeeves-server v${status.version ?? 'unknown'} running on port ${String(status.port ?? 'unknown')}.`,
|
|
266
269
|
'',
|
|
267
270
|
];
|
|
268
|
-
// Export
|
|
269
|
-
if (status.
|
|
270
|
-
lines.push('### Export
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
271
|
+
// Export capabilities
|
|
272
|
+
if (status.exports) {
|
|
273
|
+
lines.push('### Export');
|
|
274
|
+
if (status.exports.documents) {
|
|
275
|
+
lines.push('* **Documents** (Markdown/HTML): ' +
|
|
276
|
+
status.exports.documents.join(', '));
|
|
277
|
+
if (!status.exports.chromeAvailable) {
|
|
278
|
+
lines.push(' > Chrome not detected \u2014 PDF export unavailable.');
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
if (status.exports.directories) {
|
|
282
|
+
lines.push('* **Directories**: ' + status.exports.directories.join(', '));
|
|
274
283
|
}
|
|
284
|
+
if (status.exports.diagrams) {
|
|
285
|
+
lines.push('* **Diagrams**: ' + status.exports.diagrams.join(', '));
|
|
286
|
+
}
|
|
287
|
+
lines.push('* **All files**: raw download');
|
|
288
|
+
lines.push('Use `server_link_info` to check available formats for a specific path.');
|
|
275
289
|
lines.push('');
|
|
276
290
|
}
|
|
277
291
|
// Diagram support
|
|
278
|
-
if (status.diagrams
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
292
|
+
if (status.diagrams) {
|
|
293
|
+
const langs = [];
|
|
294
|
+
if (status.diagrams.mermaid)
|
|
295
|
+
langs.push('Mermaid');
|
|
296
|
+
if (status.diagrams.plantuml) {
|
|
297
|
+
const pl = status.diagrams.plantuml;
|
|
298
|
+
langs.push('PlantUML' + (pl.localJar ? ' (local jar)' : ' (server-only)'));
|
|
299
|
+
}
|
|
300
|
+
if (langs.length > 0) {
|
|
301
|
+
lines.push('### Diagrams');
|
|
302
|
+
lines.push('Supported: ' + langs.join(', '));
|
|
303
|
+
lines.push('');
|
|
304
|
+
}
|
|
282
305
|
}
|
|
283
306
|
// Connected services
|
|
284
307
|
if (status.services) {
|
|
@@ -301,10 +324,10 @@ async function generateServerMenu(apiUrl) {
|
|
|
301
324
|
}
|
|
302
325
|
lines.push('');
|
|
303
326
|
}
|
|
304
|
-
//
|
|
305
|
-
if (status.insiderCount !== undefined) {
|
|
327
|
+
// Access info
|
|
328
|
+
if (status.auth?.insiderCount !== undefined) {
|
|
306
329
|
lines.push('### Access');
|
|
307
|
-
lines.push(String(status.insiderCount) + ' insider(s) configured.');
|
|
330
|
+
lines.push(String(status.auth.insiderCount) + ' insider(s) configured.');
|
|
308
331
|
lines.push('');
|
|
309
332
|
}
|
|
310
333
|
// Sharing guidance
|
|
@@ -388,9 +411,13 @@ async function refreshToolsMd(api) {
|
|
|
388
411
|
* Start the periodic TOOLS.md writer.
|
|
389
412
|
*/
|
|
390
413
|
function startToolsWriter(api) {
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
414
|
+
// Defer first write to allow OpenClaw to fully populate api.config
|
|
415
|
+
// (plugin config may not be available at register() time).
|
|
416
|
+
setTimeout(() => {
|
|
417
|
+
refreshToolsMd(api).catch((err) => {
|
|
418
|
+
console.error('[jeeves-server] Failed initial TOOLS.md write:', err);
|
|
419
|
+
});
|
|
420
|
+
}, 5000);
|
|
394
421
|
if (intervalHandle)
|
|
395
422
|
clearInterval(intervalHandle);
|
|
396
423
|
intervalHandle = setInterval(() => {
|
|
@@ -127,7 +127,11 @@ Caddy handles TLS certificate provisioning automatically. Ensure DNS A/AAAA reco
|
|
|
127
127
|
npx @karmaniverous/jeeves-server-openclaw install
|
|
128
128
|
```
|
|
129
129
|
|
|
130
|
-
Configure the plugin in `openclaw.json` with `apiUrl` and `pluginKey` (matching the `_plugin` key seed from server config).
|
|
130
|
+
Configure the plugin in `openclaw.json` with `apiUrl` and `pluginKey` (matching the `_plugin` key seed from server config).
|
|
131
|
+
|
|
132
|
+
**Important:** Add `"jeeves-server-openclaw"` to the `tools.allow` array in `openclaw.json` so the agent can use the plugin's tools.
|
|
133
|
+
|
|
134
|
+
Restart the gateway to load the plugin.
|
|
131
135
|
|
|
132
136
|
## Troubleshooting
|
|
133
137
|
|
package/openclaw.plugin.json
CHANGED