Document xworkmate artifacts plugin
This commit is contained in:
parent
f5df5f3533
commit
fa1a9843de
42
README.md
42
README.md
@ -2,6 +2,14 @@
|
||||
|
||||
OpenClaw Gateway plugin that exports structured workspace artifact manifests for XWorkmate.
|
||||
|
||||
## Why
|
||||
|
||||
XWorkmate talks to OpenClaw through `xworkmate-bridge` using the existing
|
||||
`/gateway/openclaw` task contract. The bridge sends `chat.send`, waits for
|
||||
`agent.wait`, then asks this plugin for a structured artifact manifest. The APP
|
||||
can then sync generated files into its local thread workspace without changing
|
||||
the UI or adding provider-specific routes.
|
||||
|
||||
It registers one Gateway method:
|
||||
|
||||
```text
|
||||
@ -10,23 +18,31 @@ xworkmate.artifacts.export
|
||||
|
||||
The method scans the resolved OpenClaw workspace after a run finishes and returns safe, relative artifact entries that XWorkmate Bridge can normalize into the APP `artifacts[]` contract.
|
||||
|
||||
## Install locally
|
||||
## Install
|
||||
|
||||
Link this directory into OpenClaw:
|
||||
Install from npm:
|
||||
|
||||
```bash
|
||||
openclaw plugins install --link /Users/shenlan/workspaces/cloud-neutral-toolkit/xworkmate-artifacts
|
||||
npm install -g xworkmate-artifacts
|
||||
openclaw plugins enable xworkmate-artifacts
|
||||
```
|
||||
|
||||
Equivalent config shape:
|
||||
Or install from a Git checkout for development:
|
||||
|
||||
```bash
|
||||
git clone https://github.com/x-evor/xworkmate-artifacts.git
|
||||
openclaw plugins install --link ./xworkmate-artifacts
|
||||
openclaw plugins enable xworkmate-artifacts
|
||||
```
|
||||
|
||||
Equivalent config shape for a linked checkout:
|
||||
|
||||
```json
|
||||
{
|
||||
"plugins": {
|
||||
"load": {
|
||||
"paths": [
|
||||
"/Users/shenlan/workspaces/cloud-neutral-toolkit/xworkmate-artifacts"
|
||||
"/path/to/xworkmate-artifacts"
|
||||
]
|
||||
},
|
||||
"entries": {
|
||||
@ -74,3 +90,19 @@ Response payload:
|
||||
```
|
||||
|
||||
Files at or below `maxInlineBytes` also include `encoding: "base64"` and `content`.
|
||||
|
||||
## Limits
|
||||
|
||||
- Only files inside the resolved OpenClaw workspace are exported.
|
||||
- `.git`, `.openclaw`, `.pi`, build outputs, and dependency folders are skipped.
|
||||
- Symlinks are skipped to avoid workspace escape.
|
||||
- Files larger than `maxInlineBytes` are listed with metadata and a warning, but are not inlined.
|
||||
|
||||
## Development
|
||||
|
||||
```bash
|
||||
pnpm install
|
||||
pnpm test
|
||||
pnpm typecheck
|
||||
pnpm pack:check
|
||||
```
|
||||
|
||||
Loading…
Reference in New Issue
Block a user